From c271faee6b8d1a04726c84b1fcc5007935509202 Mon Sep 17 00:00:00 2001 From: Guilherme Rugai Freire <41879254+GRFreire@users.noreply.github.com> Date: Sat, 14 Aug 2021 11:01:35 -0300 Subject: [PATCH] zsh: add scripts to the ce fzf --- .zshrc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.zshrc b/.zshrc index db07e03..03d7e4d 100644 --- a/.zshrc +++ b/.zshrc @@ -28,8 +28,8 @@ zinit light zsh-users/zsh-completions # Alias config to manage dotfiles with git alias config="git --git-dir=\$HOME/.dotfiles/ --work-tree=\$HOME" -# Config Edit -alias ce="config ls-tree -r master --name-only \$HOME | fzf --info=inline --prompt='Select a file: ' --preview='bat --paging=never --style=plain --color=always {}' | xargs -r \$EDITOR" +# Config/scripts Edit +alias ce="echo \"\$(git --git-dir=\$HOME/.scripts/.git ls-tree -r master --name-only bin | sed 's|^|.scripts/|')\n\$(config ls-tree -r master --name-only \$HOME)\" | fzf --info=inline --prompt='Select a file: ' --preview='bat --paging=never --style=plain --color=always {}' | xargs -r \$EDITOR" bindkey -s '^e' 'ce\n' # Alias for python3