better go

This commit is contained in:
Felix Van der Jeugt 2017-01-03 15:36:06 +01:00
parent d098cb058d
commit eed51e13f3

3
zshrc
View File

@ -53,7 +53,8 @@ alias copy='urxvtc'
# FZF # FZF
function go() { function go() {
dir="$(lr /home /data -L -t 'type = d' | fzf)" #dir="$(find -L /home /data /etc -name "\.*" -prune , -type d \! -name '.git' 2>/dev/null | fzf)"
dir="$(lr /home /data /etc -L -t '(name ~~ "\.*" && prune || print) && type = d && !(name = ".git")' | fzf)"
[ -n "$dir" ] && cd "$dir" || false [ -n "$dir" ] && cd "$dir" || false
} }