Git Quick Reference

Published on Author adventurerLeave a comment

To show the differences:

% git diff

To do commit and make a first push to the remote:

% git commit -a -m "comment"
% git push -u origin master

To check diffs in the repository:

% git log -p

To check the remote repository status:

% xxx

To clone a github repository:

% git clone

To add a tag:

% git tag -a tag -m 'comment'

To push tags:

% git push origin --tags

To delete a tag from the remote:

% git push origin :tag

To delete a branch locally:

% git branch -d branchname

To delete a branch remotely:

% git push origin --delete branchname

Leave a Reply

Your email address will not be published. Required fields are marked *