From 83f593715c3ea431bf7ad4a4ad0319ac68f2188e Mon Sep 17 00:00:00 2001 From: Pavel Egorov Date: Wed, 21 May 2025 17:59:51 +0300 Subject: [fish] extract config.fish into separate files in conf.d --- .config/fish/conf.d/abbr.fish | 15 +++++++++++++++ .config/fish/conf.d/env.fish | 1 + .config/fish/conf.d/js.fish | 1 + .config/fish/conf.d/python.fish | 1 + .config/fish/config.fish | 7 ------- 5 files changed, 18 insertions(+), 7 deletions(-) create mode 100644 .config/fish/conf.d/abbr.fish create mode 100644 .config/fish/conf.d/env.fish create mode 100644 .config/fish/conf.d/js.fish create mode 100644 .config/fish/conf.d/python.fish diff --git a/.config/fish/conf.d/abbr.fish b/.config/fish/conf.d/abbr.fish new file mode 100644 index 0000000..55f0048 --- /dev/null +++ b/.config/fish/conf.d/abbr.fish @@ -0,0 +1,15 @@ +# Dotfiles helper +abbr --add dotfiles "git --git-dir=\"$HOME/.config/dotfiles/\" --work-tree=\"$HOME\"" + +# Git +abbr --add gs "git status" +abbr --add ga "git add" +abbr --add gco "git checkout" + +# ls & alternatives +abbr --add ls "eza -lAb --git --git-repos" + +# Added proxy flags +set SSPROXY 'socks5://localhost:1080' +abbr --add curlss "curl --proxy=$SSPROXY" +abbr --add ytdlpss "yt-dlp --proxy=$SSPROXY" diff --git a/.config/fish/conf.d/env.fish b/.config/fish/conf.d/env.fish new file mode 100644 index 0000000..86399b8 --- /dev/null +++ b/.config/fish/conf.d/env.fish @@ -0,0 +1 @@ +set -x MANPAGER 'nvim +Man!' diff --git a/.config/fish/conf.d/js.fish b/.config/fish/conf.d/js.fish new file mode 100644 index 0000000..dab58c6 --- /dev/null +++ b/.config/fish/conf.d/js.fish @@ -0,0 +1 @@ +fnm env --use-on-cd --shell fish | source diff --git a/.config/fish/conf.d/python.fish b/.config/fish/conf.d/python.fish new file mode 100644 index 0000000..54f931f --- /dev/null +++ b/.config/fish/conf.d/python.fish @@ -0,0 +1 @@ +pyenv init - | source diff --git a/.config/fish/config.fish b/.config/fish/config.fish index 6c72b28..e69de29 100644 --- a/.config/fish/config.fish +++ b/.config/fish/config.fish @@ -1,7 +0,0 @@ -pyenv init - | source -if status is-interactive - abbr --add dotfiles git --git-dir="$HOME/.config/dotfiles/" --work-tree="$HOME" - abbr --add ls eza -lAb --git --git-repos - - set -gx MANPAGER 'nvim +Man!' -end -- cgit v1.3