Skip to content

Commit c5bbc88

Browse files
authored
CONTRIBUTING.md updated with git workflow
1 parent f2df921 commit c5bbc88

File tree

1 file changed

+17
-21
lines changed

1 file changed

+17
-21
lines changed

.github/CONTRIBUTING.md

Lines changed: 17 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -50,27 +50,23 @@ Depending on the scale of the changes, it may be preferable to direct pull reque
5050

5151
Homer3 and AtlasViewer contain shared code including the `Utils` and `DataTree` modules. To operate both apps from the same MATLAB instance simultaneously, `setpaths` populates the MATLAB path. To avoid clobbering functions or objects, we endeavor to keep the shared code similar.
5252

53-
As of February 2022, Homer3 and AtlasViewer no longer use the Git submodule utility. The standalone repositoties still exist, but now Homer3 and AtlasViewer contain copies of the standalone repos. The file .gitmodules still exists to specify what code in Homer3 and AtlasViwer is shared libraries; that is, what code has a corresponding standalone repos as its source. The file .gitmodules is used by internal utilities that can be run to update Homer3 and AtlasViwer versions of the libraries and insure that they match the lastest standaone version.
54-
55-
DataTree and Utils (as well as Homer3 and AtlasViewer) have version files in their respective root folders called Version.txt with a simple 3-number version strings. Whenever a change is made to either the standalone version or the non-standalone versions of the libraries, the version number should be manually bumped. Then using the `synSubmodules` tool, the standalone and non-standalone versions should be made to match eachother. Here's an example of how to use it:
56-
57-
If making changes to `Homer3/DataTree` (as opposed to the standalone repo, DataTree)
58-
* Bump up the version number for `DataTree`. Version number is a simple string in `Homer3/DataTree/Version.txt`
59-
* Commit changes to `Homer3/DataTree`.
60-
* `cd` to Homer3 root folder
61-
* Run `synSubmodules.m` with no arguments. This will clone the standalone libraries (specified in `Homer3/.gitmodules`) to a folder called `Homer3/submodules` and copy the changes from the `Homer3/DataTree` to `Homer3/submodules/DataTree`
62-
* Commit changes to standalone version under `Homer3/submodules/DataTree`
63-
* Push changes to Homer3 and `Homer3/submodules/DataTree`.
64-
65-
If making change to standalone DataTree repository:
66-
67-
* Bump up the version number in `Homer3/DataTree/Version.txt`.
68-
* Commit changes changes to DataTree.
69-
* Then, to update Homer3's (or AtlasViewer's) shared libaries
70-
* Clone Homer3, run `setpaths`
71-
* Run `syncSubmodules` in `/Homer3` with no arguments
72-
* Make any supporting changes in non-shared portion of Homer3 associated with the library changes.
73-
* Commit changes to Homer3
53+
As of February 2022, Homer3 and AtlasViewer no longer use the Git submodule utility. The standalone repositoties still exist, but now Homer3 and AtlasViewer contain copies of the standalone repos. The file .gitmodules still exists to specify what code in Homer3 and AtlasViwer is shared libraries; that is, what code has a corresponding standalone repos as its source. The file .gitmodules is used by internal utilities that can be run to update Homer3 and AtlasViwer versions of the libraries and insure that they match the lastest standaone version.
54+
55+
To keep Homer3 in step with its submodule repositories:
56+
57+
1. Make changes in Homer3 (and its copy of the shared code)
58+
2. Commit & push changes to a fork of Homer3.
59+
3. Open pull request to integrate with `BUNPC:Homer3` and link to PR created in Step 6 below.
60+
4. Set up local Homer3/<shared module> to track fork of shared module, i.e. `DataTree`
61+
```
62+
cd Homer3/DataTree
63+
git init
64+
git remote add origin https://github.com/jayd1860/DataTree
65+
git fetch
66+
git reset --mixed origin
67+
```
68+
5. Commit & push changes to a fork of shared module
69+
6. Open pull request to integrate with `BUNPC:<shared module>`, and link to PR in Step 3 above.
7470

7571
## Development environment
7672

0 commit comments

Comments
 (0)