Skip to content

Instantly share code, notes, and snippets.

@mikiyaf
Created November 13, 2017 01:20
Show Gist options
  • Save mikiyaf/c1827e056a8b3fd7a69b20b680c924df to your computer and use it in GitHub Desktop.
Save mikiyaf/c1827e056a8b3fd7a69b20b680c924df to your computer and use it in GitHub Desktop.
fh - repeat history
fh() {
print -z $( ([ -n "$ZSH_NAME" ] && fc -l 1 || history) | fzf +s --tac | sed 's/ *[0-9]* *//')
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment