Forked from derek-duncan/1-suggested-branch-naming-scheme.rb
Last active
May 28, 2020 13:50
-
-
Save BrunoAndinaDeFi/4e3be7c7843a4720eefd5353110a9698 to your computer and use it in GitHub Desktop.
Git workflow for Andina DeFi
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# [jira-ticket-id]-[feature-name] | |
# All lowercase. Spaces replaced with dashes | |
123-rif-on-chain |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Pull newest updates from master | |
git checkout master | |
git pull origin master | |
# Create your feature branch | |
git checkout -b 123-rif-on-chain | |
# ..work and commit some stuff. | |
# Commit to remote branches if needed (recommended). | |
# Ready to push? Okay. First, fix all conflicts between develop and 1234-my-new-feature on your local so we can simply fast-forward when we push. | |
git fetch origin | |
git rebase origin/develop | |
# QA on local machine. If updates, repeat previous step | |
# Merge your feature into develop. Also, let's squash it into one commit | |
git checkout develop | |
git merge 123-rif-on-chain | |
git commit -m "added RIF on Chain" | |
# Push | |
git push | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ..you need to push updates after QA | |
# Checkout your branch to make updates | |
git checkout 123-rif-on-chain | |
# ..update and commit stuff | |
git fetch origin | |
git rebase origin/develop | |
# QA on local machine. If updates, repeat previous step | |
# Merge the updated branch into develop | |
git checkout develop | |
git merge 123-rif-on-chain | |
git commit -m "updated RIF on Chain" | |
# Push | |
git push |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Fix all conflicts between develop and master before we merge | |
git checkout develop | |
git merge master | |
git checkout master | |
git merge -m 'Release 0.3.1+21 - Welcome RIF on Chain' develop | |
git push | |
# We don't want to squash the develop commits on master so we can exclude any blockers when it comes time to push to master |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# [Optional] Delete local branch if you're done developing | |
git branch -D 1234-my-new-feature |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
http://stackoverflow.com/questions/457927/git-workflow-and-rebase-vs-merge-questions | |
http://stackoverflow.com/questions/1241720/git-cherry-pick-vs-merge-workflow |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment