Shell history is not a command library.
Your shell history remembers commands you ran. It does not always remember what you need to run them successfully next time.
What shell history does well
History is useful when you want to repeat something you just typed. Search for an old command, edit it, and press Enter. For one-off work, that is often enough.
What gets lost in history
A command is often more than one line of text. To run it again, you may also need:
- the working directory;
- environment variables or a selected environment;
- prompt values and other parameters;
- setup, cleanup, or follow-up commands;
- a reminder of what the command is for.
Shell history usually stores the line you entered, in chronological order. It is not organized around the workflows you return to every week.
Where cmdbook fits
cmdbook is a local library for commands and their setup. Save a command once, keep its context with it, put related commands in folders, and run it again when you need it.
Use cmdbook for the commands and scripts you expect to run again.
It does not replace your terminal. It gives repeatable command-line work a place where it can be found and started without reconstructing the setup from memory.
When should you use each one?
- Shell history: repeat a recent command or inspect what you just ran.
- cmdbook: save a recurring command, a long-lived process, an interactive command, or a workflow with context.