Tool - Git - commands overview
Just a quick overview about some git commands
- git init | creates a repository in the current directory
- git branche $mybranch | creates the branch $myBranch
- git add $file | adds a file to the index/staging
- git status | shows the status of the current branch
- git diff [$file | $directory | $branchname | $commitId] | displays the diff between the current and the wished $item
- git checkout $branch | switch to branch $branch
- git checkout -b $branch | creates the branch $branch from the current branch and switch to branch $branch
- git merge $branch | merge current branch with $branch
- git log | shows the log
- git hist | shows the history
- git commit | commit the changes from the index to the repository
- git commit -a | adds the modified $items to the index and commit to the repository
- git rebase -i master | there you can squash commits
- git remote add $uri | adds the source $uri to your git
- git pull | fetch and merge from remote into current branch
- git-achievements | super secret cool stuff ;-)
A greate introduction into the git concept can be seen here
Kommentare
Ansicht der Kommentare: Linear | Verschachtelt