Teis Lindemark
git config --global user.name "Ditt navn"
git config --global user.email "Ditt navn@acos.no"
Start git bash
$ ssh-keygen
git clone
Clones a repository into a newly created directory, creates remote-tracking branches for each branch in the cloned repository, and creates and checks out an initial branch that is forked from the cloned repository’s currently active branch.
https://git-scm.com/docs/git-clone
git clone git@git.intern.acos.no:teis/git-intro.git
git pull
Incorporates changes from a remote repository into the current branch. In its default mode, git pull is shorthand for git fetch followed by git merge FETCH_HEAD.
More precisely, git pull runs git fetch with the given parameters and calls git merge to merge the retrieved branch heads into the current branch. With --rebase, it runs git rebase instead of git merge.
https://git-scm.com/docs/git-pullgit add
This command updates the index using the current content found in the working tree, to prepare the content staged for the next commit. It typically adds the current content of existing paths as a whole, but with some options it can also be used to add content with only part of the changes made to the working tree files applied, or remove paths that do not exist in the working tree anymore.
https://git-scm.com/docs/git-addgit commit
Stores the current contents of the index in a new commit along with a log message from the user describing the changes.
https://git-scm.com/docs/git-commitgit push
Updates remote refs using local refs, while sending objects necessary to complete the given refs.
https://git-scm.com/docs/git-pushgit fetch
Fetch branches and/or tags (collectively, "refs") from one or more other repositories,
along with the objects necessary to complete their histories.
Remote-tracking branches are updated (see the description of
git checkout
Updates files in the working tree to match the version in the index or the specified tree. If no paths are given, git checkout will also update HEAD to set the specified branch as the current branch.
https://git-scm.com/docs/git-checkoutgit branch
git-branch - List, create, or delete branches
https://git-scm.com/docs/git-branchgit rebase
git-rebase - Reapply commits on top of another base tip
https://git-scm.com/docs/git-rebasegit config --global alias.XX git_kommando
$ git config --global alias.co checkout
$ git config --global alias.br branch
$ git config --global alias.ci commit
$ git config --global alias.st status
git log --branches --not --remotes --simplify-by-decoration --decorate --oneline
...
git stash
git-stage - Add file contents to the staging area
https://git-scm.com/docs/git-stage