zimfw/smite
A function that makes it easier to opt-out of typos and dead ends in your shell history.
smite
A function that makes it easier to opt-out of typos and dead ends in your shell
history. By Benjamin Esham, from his blog post "Curate your shell history".
Running
smiteopens an fzf-powered browser with your shell history in it.
(So you'll need fzf installed, but that's the only dependency.) By default,
you'll only see your history from the current session, but runningsmite -a
shows all of your history.When you navigate to an entry and press
ReturnorEnter, zsh will delete
all instances of that command from your history. If you want to delete
multiple commands at once, you can select them by pressingTabon each one
and then typingReturnto commit your changes.Multiline commands are not handled correctly, for now.
The function prints back all of the commands it's deleting, just in case you
select the wrong one.
Requirements
You'll need fzf installed.