Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a bunch of commands that I commonly use. For example:

du -h --max-depth=1 /home

Unfortunately, my brain has very little room left for these sorts of things. I currently keep a text file on my desktop for jotting down these commands -- but I'm wondering if there's a better way to do this right from the command line...

Ideally, I could create a alias command that would open a list of my favorite commands...for example:


would open my list of favorite commands and then I could quickly copy and exit that to do the command. Anybody got a workflow they'd like to suggest on this?

share|improve this question

You can use ctrl+r, start typing a command and then a suggestion will appear of a command in you previously used (and that's in the history).

share|improve this answer

I can only tell you what I do, since there are a billion ways to approach this. We use Puppet for systems management at my company so I populate my .bashrc with lots of functions and aliases. For example (your example reminded me of mine):

alias sp='du -mx . --max-depth=1 | sort -nr | head'

If I ever want to remind myself what I've done, I can look at .bashrc, type alias and/or declare -f (to see functions loaded into my shell).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.