It’ll copy the text in your current command line into your $EDITOR. Saving and quitting your editor will put the modified text back into your command line. Never fear long commands again!
## arrow up
"\e[A":history-search-backward
## arrow down
"\e[B":history-search-forward
but it works only for beginning of the line. CTRL + R shows results with keyword anywhere within the line and pressing it again shows next result. CTRL + Shift + R goes back one result.$ cd ~/src/app/foo/bar/baz
$ pushd /etc/qux/quux/quuz/corge/grault/garply/waldo
$ popd
$ pwd
/home/you/src/app/foo/bar/baz
It's a stack of directories. You pushd the current directory on to the stack and cd to a new directory all in a single command, then you popd back to the previous directory (i.e., the one on the top of the stack). It's useful if you're jumping all over the filesystem to do work, or if someone interrupts you and you want to cd somewhere to show them the contents of a file without losing your own context.
so if you cd to /usr/home/me/tacos once, from then on you can just > j taco
and it will cd to that directory. Saves so much time! Instead of typing out /etc/nginx you can just type "j e ng" and it will jump there.
Thanks!
I didn't, thank you. It works both in bash and powershell.