|
git pull // Get the latest code
git branch testbranch // Create a branch
git branch // Look at existing branches
git checkout testbranch // Switch to the branch
vi aFile.java // Edit some code
git diff // Look at what has changed
git status // Shows what branch you are on, what has changed, what is in the staging area, etc.
git add // Add a file to the staging area
git status // Look at the difference in the status
git commit // Create a commit using the changes in the staging area
git log // See that our commit has been added to the log
git checkout master // Switch to the master branch
git pull // Get the latest code
git checkout testbranch // Switch to testbranch
git rebase master // Replay local commit on top of the latest code
git checkout master // Switch to the master branch
git merge testbranch // Merge changes with master
git push // Push your patch out for public consumption
git branch -d testbranch // Delete the branch
|
|
|