commit 8f45f21476a45583e03334a226aa579c128a2283 parent e9799c2a402acecd03f4e6d8701c5976b55c31a4 Author: Alexander Balgavy <alexander.balgavy@spaceapplications.com> Date: Mon, 2 Oct 2023 17:42:21 +0200 shell: fix paths Diffstat:
M | shell/functions | | | 6 | +++--- |
M | shell/paths | | | 2 | +- |
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/shell/functions b/shell/functions @@ -91,7 +91,7 @@ if [ -d ~/.config/fzf ]; then # script edit se() { local files - IFS=$'\n' files=($(command find "$(readlink ~/.scripts)" -type f -or -type l -not -ipath "*/.git/*" | fzf -m --inline-info --prompt="edit> " --height=40 --reverse)) + IFS=$'\n' files=($(command find "$DOTFILES/scripts" -type f -or -type l -not -ipath "*/.git/*" | fzf -m --inline-info --prompt="edit> " --height=40 --reverse)) [[ -n "$files" ]] && ${EDITOR:-vim} "${files[@]}" } # script create @@ -110,14 +110,14 @@ if [ -d ~/.config/fzf ]; then # config edit ce() { local files - IFS=$'\n' files=($(command find ~/.dotfiles -type f ! -ipath "*/scripts/*" ! -ipath "*/.git/*" ! -ipath "*/bin/*" ! -ipath "*/oh-my-zsh/*" ! -name ".DS_Store" | fzf -m --inline-info --prompt="edit> " --height=40 --reverse)) + IFS=$'\n' files=($(command find "$DOTFILES" -type f ! -ipath "*/scripts/*" ! -ipath "*/.git/*" ! -ipath "*/bin/*" ! -ipath "*/oh-my-zsh/*" ! -name ".DS_Store" | fzf -m --inline-info --prompt="edit> " --height=40 --reverse)) [[ -n "$files" ]] && ${EDITOR:-vim} "${files[@]}" } # config find cf() { local f - IFS=$'\n' f=($(command find ~/.dotfiles -type f ! -ipath "*/.git/*" ! -ipath "*/bin/*" ! -ipath "*/oh-my-zsh/*" ! -name ".DS_Store" | fzf +m --prompt="find> " --height=40 --reverse --cycle)) + IFS=$'\n' f=($(command find "$DOTFILES" -type f ! -ipath "*/.git/*" ! -ipath "*/bin/*" ! -ipath "*/oh-my-zsh/*" ! -name ".DS_Store" | fzf +m --prompt="find> " --height=40 --reverse --cycle)) [[ -n "$f" ]] && printf "$f" } diff --git a/shell/paths b/shell/paths @@ -9,7 +9,7 @@ [ -d "$HOME/.local/gnat/bin" ] || [ -L "$HOME/.local/gnat/bin" ] && [ -n "${PATH##*"$HOME/.local/gnat/bin"*}" ] && PATH="$HOME/.local/gnat/bin:$PATH" [ -d "$HOME/bin" ] || [ -L "$HOME/bin" ] && [ -n "${PATH##*"$HOME/bin"*}" ] && PATH="$HOME/bin:$PATH" [ -d "$HOME/.bin" ] || [ -L "$HOME/.bin" ] && [ -n "${PATH##*"$HOME/.bin"*}" ] && PATH="$HOME/.bin:$PATH" -[ -d "$HOME/.scripts" ] || [ -L "$HOME/.scripts" ] && [ -n "${PATH##*"$HOME/.scripts"*}" ] && PATH="$HOME/.scripts:$PATH" +[ -d "$HOME/Documents/dotfiles/scripts" ] || [ -L "$HOME/Documents/dotfiles/scripts" ] && [ -n "${PATH##*"$HOME/Documents/dotfiles/scripts"*}" ] && PATH="$HOME/Documents/dotfiles/scripts:$PATH" [ -d "$XDG_DATA_HOME/gem/bin" ] || [ -L "$XDG_DATA_HOME/gem/bin" ] && [ -n "${PATH##*"$XDG_DATA_HOME/gem/bin"*}" ] && PATH="$XDG_DATA_HOME/gem/bin:$PATH" [ -d "$HOME/.elan/bin" ] && [ -n "${PATH##*"$HOME/.elan/bin"*}" ] && PATH="$HOME/.elan/bin:$PATH" [ -d /usr/local/opt/man-db/libexec/bin ] && [ -n "${PATH##*"/usr/local/opt/man-db/libexec/bin"*}" ] && PATH="/usr/local/opt/man-db/libexec/bin:$PATH"