Most of time I do use SourceTree for Mac which is pretty stable but sometimes I do have only command line with tmux. So I need to write commands by myself here are cheat tables:
CONFIGURE STUFF
$git config --global user.name "[magic name]" $git config --global user.email "[super email]" $git config --global color.ui autoI think all is almost self explanatory and coments are note necessary
CREATE REP.
$git init [your-project-name] $git clone [project-url]
MAKE GREAT CHANGES
$git status $git diff $git diff --staged $git add [cool/not cool files] $git reset [only not cool files:)] $git commit -m "[please inform]"
DO GROUP CHANGES...
$git branch $git branch [desired-branch-name] $git branch -d [branch-you-dont-want] $git checkout [some-branch-you-want] $git merge [a-lot-fun-branch]
TIME TO REFACTOR FILES
$git rm [file-I-dont-want] $git rm --cached [file-to-remove-but-stay-locally] $git mv [where-file-is] [here-file-goes]
HISTORY COUNTS
$git log $git log --follow [my-favorit-file] $git diff [branch-I-ve-worked-on1]...[another-branch-some-else-worked-one] $git show [magic-commit]
CHANGE (REDO) COMMITS
$git reset [moving-from-corrupted-branch-to-ok-branch] $git reset --hard [please-move-me-into-this-branch]
SAVE FRAGMENTS
$git stash $git stash pop $git stash list $git stash drop
ALL CHANGES ARE IMPORTANT...
$git fetch [favorite-bookmark] $git merge [bookmark-I-need]/[magic-branch] $git push [alias] [favorite-branch] $git pull
And it's not all but enough to make a great GIT job great again!
No comments:
Post a Comment