Extract a single hash-like pattern from each line

Close #15
main
Junegunn Choi 2 years ago
parent a409f051ec
commit a48b941487
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

@ -180,7 +180,7 @@ _fzf_git_hashes() {
--bind 'ctrl-d:execute:grep -o "[a-f0-9]\{7,\}" <<< {} | head -n 1 | xargs git diff > /dev/tty' \
--color hl:underline,hl+:underline \
--preview 'grep -o "[a-f0-9]\{7,\}" <<< {} | head -n 1 | xargs git show --color=always' "$@" |
grep -o "[a-f0-9]\{7,\}"
awk 'match($0, /[a-f0-9]{7,}/) { print substr($0, RSTART, RLENGTH) }'
}
_fzf_git_remotes() {

Loading…
Cancel
Save