Skip to content
Myr

Merge pull request #20 from wellle/zsh-history-fc

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Use `fc` instead of `history` to avoid `oh-my-zsh` alias

authored by Junegunn Choi · committed by Junegunn Choi · parents 00c8a68, f5d53b9 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:install+1 added-1 removed
148 unmodified lines
149bindkey '\ec' fzf-cd-widget150151# CTRL-R - Paste the selected command from history into the command line152fzf-history-widget() {153 LBUFFER=$('history' -$HISTSIZE | fzf +s | sed "s/ *[0-9]* *//")153 LBUFFER=$(fc -l 1 | fzf +s | sed "s/ *[0-9]* *//")154 zle redisplay155}156zle -N fzf-history-widget157bindkey '^R' fzf-history-widget
32 unmodified lines