Created
January 24, 2012 11:12
-
-
Save ismasan/1669672 to your computer and use it in GitHub Desktop.
Simple git workflow
This file contains hidden or 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
# 1. Pull latest changes from remote repository | |
$ git pull | |
# Git will tell you if you have conflict. If so, fix each file individually and commit the fix. | |
# 2. Starting a new feature | |
# Create a "feature branch". Each new piece of functionality lives in it's own branch | |
$ git checkout -b my_new_feature | |
# 3. Work and commit your changes. Keep commits small and self-contained. Commit messages should be descriptive. | |
# 4. Go back to "master" and pull latest changes from server | |
$ git checkout master | |
$ git pull | |
# 5. Merge your local feature branch onto master | |
$ git merge --no-ff my_new_feature | |
# 6. Fix conflicts, if any. Commit fix. | |
# 7. Push your changes to remote server | |
$ git push |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment