Git Assume Unchanged

Git is far and away the best revision control system I've ever used. As evidence, I submit this little gem of a command:

repo$ git update-index --assume-unchanged file1 file2 ...

This is a useful command to use when you want to change a file locally and prevent it from being committed back to the repository. Once you're done and want to re-enable commits of those files, simply re-run the command and use --no-assume-unchanged.


UTOSC 2010 Day 2: Advanced Git

Git has become my favorite version control of late, so I was very excited about this presentation. With that, I attended Tim Harper's presentation on Advanced Git. We got started 30 minutes late, he had some technical issues with his content, and we ended up with only 15 minutes of class time. That was a real disappointment. I did learn about gitk, a repository visualizer. I think I have a somewhat better idea on how to browse around my branches.

Miscellaneous Notes:

  • rebase
  • clean commits
  • bisect
  • always review before you commit
  • git add -p - yes/no before it adds
  • gitk - repository visualizer. gitk --all
  • tig - console visualizer
  • git log branch1...branch2 - show changes that are same in both branches
  • git reflog
  • lose your head


Subscribe to RSS - git Subscribe to - All comments