←back to thread

6 points afefers | 1 comments | | HN request time: 0.206s | source

What are the most useful/essential things in your shell configuration file. Be it custom function, wrappers, aliases, etc. Please provide an explanation since it isn't always obvious to others.
1. wruza ◴[] No.41921183[source]
I always alias rm, mv, cp, ln to -i.

Also, gt, gtt, gl, ga, gc, gu, gp, gd, gd2 for git status -s, status, log, add, commit, pull, push, diff, diff to rev. All with useful (to me) flags.

My prompt looks like this:

  \n
  [<status>] user@site [<cwd>]\n
  $ 
So that I see where I am, all commands line up, the last status is obvious and also there’s never this:

  $ cat nonewline.txt
  Oops no newline$ _
My .inputrc always contains https://stackoverflow.com/a/1030206