Check for changes
git fetch --allgit status
Compare
#current vs staged (local repository, previous to upload?)git diff#compare current against stagedgit diff <filename># in git > 1.6.1 cached replaced by stagedgit diff --staged#staged vs committedgit diff --staged <filename>
# browse changes
git loggit log -p #shows differences between commitsgit log -p -2 #limits output to 2 last commits
If you think that there will be conflicts, try to merge in dry-run mode
git merge --no-commit --no-ff $BRANCH #Get the commits but do not apply yet
git merge --abort #Discard last changes
If, anyway, conflict appears:
- Solve the conflict: vi your/file.py
- git add your/file.py
- [git commit -m "Conflict solved"]
No comments:
Post a Comment