Updating My Linux Command line Toolbox, episode 2

by gorthx

Part 1

Five more, all from this week:

1. date -u to get your date in UTC

2. pushd and popd – create your own directory stack.  I’m still trying this one out.  (“why not just use the up arrow?”)

3. pbcopy – copy to clipboard from the command line.

4. !$ contains the last arg of the previous command, so you can do something like this:
ls -l filename.*    # check what you have in the dir
vi !$

5. This one is my favorite: !?[string] runs last command that contains that string.

Advertisements
Tags: ,

3 Comments to “Updating My Linux Command line Toolbox, episode 2”

  1. Try control-r, type partial command, then up/down arrow.

  2. popd & pushd are for use in scripts …

%d bloggers like this: