I have a lot of commands I routinely need to execute, often with the slightest variation.
Right now I'm storing them all in .bash_history and use CTRL-R to access them, but I wonder if there's a better way. What I'm looking for:
- Easy to add a new command
- Easy to search and re-execute a wanted command
- Avoid unwanted commands in suggestions
Unfortunately, bash_history is not so strong on the third demand: if I do a few
ls, it fills the history file quickly. I have recently learned about HIST_SIZE and that you can configure the history to avoid duplicates or certain commands, but before configuring all that, I wanted to make sure it is the best way.