Created
October 1, 2010 13:48
-
-
Save pfleidi/606236 to your computer and use it in GitHub Desktop.
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
# init | |
git init | |
# add files | |
git add . | |
# commit files | |
git commit -m 'add file' | |
# create branch and check it out | |
git checkout -b testbranch | |
# show branches | |
git branch | |
# modify file in testbranch | |
echo "modifiy file in branch" >> test.txt | |
# commit to testbranch | |
git commit -a -m 'modified file' | |
# switch to master | |
git checkout master | |
# merge changes to master | |
git merge testbranch | |
# check if your commits are there | |
git log | |
# look at the file | |
cat test.txt | |
Hallo | |
modifiy file in branch <- merged change |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment