CASE #1 - Changing which revision of a dependency a feature branch depends on
Current process:
cd parent-repo
git checkout master
git pull --rebase
git checkout -b feature_branch
cd gem
git pull --rebase
git checkout -b feature_branch
<make change>
git commit
cd .. # back to parent-repo
bundle check # updates Gemfile.lock
git commit # commits update to pointer
CASE #2 - Committing a change to a dependency
Current process:
cd parent-repo
git checkout master
git pull --rebase
git checkout -b feature_branch
cd gem
git checkout master
git pull --rebase
git checkout -b feature_branch
<make a change>
git commit
CASE #3 - Merging dependency revision change to release branch
Current process:
cd parent-repo
git checkout master
git pull --rebase
cd gem
git checkout master
git pull --rebase
git merge feature_branch # merge the feature branch into the gem release branch
cd .. # back to parent-repo
bundle check # updates Gemfile.lock
git commit # commits update to pointer
# We merge the gem feature branch into the gem master branch, then update
# the revision in parent-repo:master’s Gemfile.lock.
# This is so multiple branches can get merged into the same release branch of gem.
CASE #4 - Ensuring local code is up-to-date
Current process:
cd repo
git checkout master
git pull --rebase
# checks to ensure the revision of gem pointed to in Gemfile.lock is the local revision
# and warns if not
bundle check