TIL git checkout -. The minus (-) at the end of the command tells git to switch to the previous branch you were on before the current one. It’s a way to quickly toggle back and forth between two branches without needing to type out the full branch names.

TIL pushd and popd: git worktree example:

$ git worktree add -b emergency-fix ../temp master
$ pushd ../temp
# ... hack hack hack ...
$ git commit -a -m 'emergency fix for boss'
$ popd
$ git worktree remove ../temp

TIL about Typed throws in Swift.