Re:Show HN: Teleport: Simple command line app tutorial writt...
by jastanton on Thursday December 22, 2016 @03:58PM
(#13240343)
A trick I commonly use is:
Which goes back to the previous directly I was just on. They have the same thing for git as well:
it's quite handy for switching back and forth between branches or directories!
[ Parent
| on HN ]
Re:Show HN: Teleport: Simple command line app tutorial writt...
by Fnoord on Saturday December 24, 2016 @05:57PM
(#13251972)
I was using $OLDPWD and your solution is much shorter, cheers. Both also work in my shell, Fish. Perhaps obvious, but it is also possible to use cd - twice to get back to orig.
Re:Show HN: Teleport: Simple command line app tutorial writt...
by gbersac on Thursday December 22, 2016 @06:22PM
(#13241357)
Thanks for gi checkout -. I am currently using git checkout @{-1} which does the same thing...in a more verbose way.