Olivet University - Olivet Institute of Technology

RSS

Version control best practices

Best practices

  • Diff before you commit
  • Keep commits small and logical
  • There is room for comments, use it!
  • Build and test code before a commit
  • Don’t leave commented code in there
  • Check other people’s commits

Best practices (GIT edition)

  • Use .gitignore
  • Commit often
  • Be careful with git reset
  • Rewriting history
  • Branching
    • Choose a workflow for branching
    • Merge often and stay up to date
    • Post-merge delete
  • Tag releases
  • Stashing
  • Experiment!

Check the whole post here and here.