Commit 38f2f222 authored by French, Robert's avatar French, Robert Committed by GitLab
Browse files

Ready for Gitting Unlost Talk

parent 51562501
<!-- $theme: gaia -->
<!-- *template: invert -->
# Don't Panic: Gitting Unlost
### Tom Barron & Robert French
......@@ -20,8 +21,7 @@ In this workshop, we'll show how to:
* navigate your git repo,
* salvage your current state, and
* some other tricks for getting back to a sane environment.
* add some stuff about fancy log formats for understanding my network of branches
* add more stuff
---
......@@ -99,7 +99,7 @@ But no, the output of 'git log' now starts with the commit I just checked out. H
---
And now 'git log' shows everything again
### And now 'git log' shows everything again
$ git log --pretty=oneline
......@@ -148,7 +148,7 @@ What gives?
---
### How come git status isn't always the same?
git provides the remote status when the branch is set
git provides the remote status when the branch is set to track upstream
```
$ git push -u origin untracked
......@@ -156,3 +156,38 @@ $ git status
On branch untracked
Your branch is up-to-date with 'origin/untracked'.
```
---
## Visualizing Branch states
```bash
$ git log --graph --simplify-by-decoration \
--pretty=format:'%d' --all
* (HEAD -> tpb-rf9-dont-panic-gitting-unlost, origin/tpb-rf9-dont-panic-gitting-unlost)
* (rf9/dummy)
* (origin/untracked)
| * (origin/master, origin/HEAD)
| | * (origin/update-workshop-schedule)
| |/
| * (origin/ci-runners-talk, ci-runners-talk)
| * (master)
|/
*
```
---
## Visualizing Branch states
Make this an alias!
```
$ git config --global alias.tree \
"log --graph --simplify-by-decoration \
--pretty=format:'%d' --all"
```
---
<!-- *template: invert -->
# Questions?
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment