No maintained cheat sheet here either. I do use `history | grep` quite a lot though.

One thing I try to do is to keep my keyboard shortcuts consistent between programs/systems. That way the chance of my instinct of pressing `+a` to move the cursor to the start of the line will be correct more often.

Another thing I try to do when a project has a set of complex commands that are needed, is to add them as a rule in its Makefile, that way they're available for my colleagues as well.

I use zsh-histdb[1], which records my entire shell history for all time in a database, which also stores:

  • The start and stop times of the command
  • The working directory where the command was run
  • The hostname of the machine
  • A unique per-host session ID, so history from several sessions is not confused
  • The exit status of the command
This the working directory of the command has been especially useful for me to get the context of what I did, not only the command itself.

[1] - https://github.com/larkery/zsh-histdb