This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##################################### | |
# Useful commands that leverage fzf # | |
##################################### | |
# Fuzzy file open: Type ff and find file via fzf and open in nvim | |
ff() { nvim "$(find . -type f | fzf)"; } | |
# Fuzzy cd: Type fcd and select folder via fzf | |
fcd() { cd "$(find . -type d | fzf)"; } | |
# Fuzzy git branch checkout: Type fgc and select branch via fzf | |
fgc() { git switch "$(git branch -v | fzf | awk '{print $1}')"; } | |
# Fuzzy git add: Type fga and select file via fzf |