programmieren:git
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| programmieren:git [2020/04/08 16:18] – [nützliche Kommandos] felix | programmieren:git [2023/09/01 16:33] (current) – [nützliche Kommandos] felix | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Git ====== | ====== Git ====== | ||
| - | ===== Tutorials ===== | ||
| - | * Derek Banas' [[https:// | ||
| - | * [[http:// | ||
| - | * [[https:// | ||
| - | * [[http:// | ||
| - | * [[http:// | ||
| - | * [[https:// | ||
| - | ==== Branches ==== | + | ===== Branches |
| * GitHub: [[https:// | * GitHub: [[https:// | ||
| * Atlassian: [[https:// | * Atlassian: [[https:// | ||
| Line 19: | Line 12: | ||
| ===== nützliche Kommandos ===== | ===== nützliche Kommandos ===== | ||
| * alle Branches auf dem Server (aka " | * alle Branches auf dem Server (aka " | ||
| + | * Liste aller Branches (lokal + serverseitig): | ||
| + | * lokale Branches löschen, die auf dem Server-Repo bereits gelöscht sind: <code bash>git branch --v | grep " | ||
| + | </ | ||
| + | |||
| + | ==== Zusammenführen ==== | ||
| + | * einzelne Commits nacheinander anwenden <code bash>git cherry-pick abc321 efg654 xyz890</ | ||
| + | * <code bash>git pull --rebase origin master</ | ||
| * Branch auf Server löschen (nach dem Merge und nachdem man den Feature-Branch lokal gelöscht hat): <code bash>git push origin : | * Branch auf Server löschen (nach dem Merge und nachdem man den Feature-Branch lokal gelöscht hat): <code bash>git push origin : | ||
| + | |||
| + | ==== Darstellung ==== | ||
| * Ausgabe der kompletten Historie als Graph: <code bash>git log --color --graph --oneline --all --decorate</ | * Ausgabe der kompletten Historie als Graph: <code bash>git log --color --graph --oneline --all --decorate</ | ||
| - | * alle Branches auf dem Server (aka “origin”) im aktuellen Repository anzeigen: <code bash> | + | * kompaktere Ausgabe: <code bash> |
| + | * Namenskonvention für Branches: '' | ||
| + | * neuen Branch anlegen: <code bash>git checkout master | ||
| + | git pull | ||
| + | git checkout -b DEIN_BRANCH_NAME | ||
| + | git push</ | ||
| + | * Code zwischenlagern, | ||
| + | git stash | ||
| + | git pull | ||
| + | git stash pop</ | ||
| ====== Themes ====== | ====== Themes ====== | ||
| ===== base16-monokai ===== | ===== base16-monokai ===== | ||
programmieren/git.1586355522.txt.gz · Last modified: by felix
