Page MenuHomePhabricator

Git and Arcanist Reference
Updated 2,236 Days AgoPublic

Git Cheat Sheet by Alex Kras (RECOMMENDED)
19 Tips for Everyday Git Use by Alex Kras (RECOMMENDED)

Atlassian: Basic Git Commands
Understanding Git vs. SVN

Reference Charts

Branching
Flowchart: Branching.png (1×816 px, 146 KB)
Commit Workflow
Flowchart: Commit Workflow.png (1×816 px, 219 KB)
Git and Arcanist
Flowchart: Git and Arc.png (816×1 px, 247 KB)
Visualizing Version Tracking
Flowchart: Version Tracking.png (1×816 px, 300 KB)
Where To Commit?
Flowchart: Where To Commit.png (1×816 px, 237 KB)

Quick Reference

Download a repository.

$ git clone <URL>

Get updates with...

$ git pull

Lint files...

$ arc lint --lintall

Send new changes with...

$ git add .
$ git commit
# Fill out the message.
$ arc diff

Commit approved changes to branch with...

$ arc amend
$ git push origin foo
# foo is the branch name.

Branches

You can move work out of master into a branch at any time.

To view all branches...

$ git branch

To create a branch named "foo".

$ git branch foo

To move work to the "foo" branch...

$ git checkout foo

To merge the current branch down to master.

$ arc land

To merge master into the current branch.

$ git merge master
Last Author
jcmcdonald
Last Edited
Jun 30 2016, 10:13 AM

Event Timeline

jcmcdonald edited the content of this document. (Show Details)
jcmcdonald changed the title from Git to Git and Arcanist Reference.Jan 6 2016, 9:53 PM
jcmcdonald edited the content of this document. (Show Details)
jcmcdonald edited the content of this document. (Show Details)