-
Notifications
You must be signed in to change notification settings - Fork 42
Version Control
Kanit Wongsuphasawat edited this page Jun 27, 2016
·
9 revisions
- Git Tutorials
- Github
- Guide
- Use Github's issue tracker, so you can refer to issues in your commit messages using # followed by issue no.
- Working in a team? Use Github's Pull Request so you can do code review.
- Github Cheatsheet
- GUI
- Using git with command line is generally fast but using SourceTree is easier for reviewing your code before committing or committing a part of your changes and reduce chances that you will run a wrong command (such as push wrong branch to master).
- GitX is a simple GUI that can also be started from the command line.
-
Atomic Commit is a good practice
-
Stash is useful when you have unfinished messy things and need to switch branches to work on something else.
-
Interactive Rebase is useful for making your commit logs cleaner.
-
Need to merge multiple repos (e.g. using datavore in another project)? Use git subtree and DO NOT use git submodule.
-
To make
git push
only push current branch by default, trygit config --global push.default current
-
Github's merge squash =
git rebase -i master
and squash all commits + push result to master -
Github merge =
git checkout master && git merge <branch> —no-ff
-
If you want linear history without squashing, manually do
git checkout master && git merge <branch>
(without—no-ff
) would make the result linear too.
Resources
- Visualization Tools
- Web Development (HTML, CSS, Javascript)
- D3
- Version Control