From 457f339f13f244c3020a17513b8b7632cf529e43 Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Mon, 21 Aug 2023 17:39:00 +0200 Subject: Updated fish config to use virtualfish --- config/fish/config.fish | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'config/fish') diff --git a/config/fish/config.fish b/config/fish/config.fish index eed9229..1953bb9 100644 --- a/config/fish/config.fish +++ b/config/fish/config.fish @@ -92,7 +92,11 @@ if status is-interactive alias yay 'yay --color=auto' alias tree 'tree -C' alias less 'less -N' # enable line number - alias nvim 'VIMINIT="" /usr/bin/nvim' + if [ "$(uname)" = 'Darwin' ] + alias nvim 'VIMINIT="" /usr/local/bin/nvim' + else + alias nvim 'VIMINIT="" /usr/bin/nvim' + end alias v 'nvim' alias gdb 'gdb -q' # disable long intro message alias sudo 'sudo ' # enable color (the search for aliases continues) @@ -173,7 +177,14 @@ if status is-interactive set pure_reverse_prompt_symbol_in_vimode true function fish_command_not_found - /usr/bin/pkgfile $argv[1] + if [ "$(uname)" = 'Linux' ] + /usr/bin/pkgfile $argv[1] + end + end + + # from: https://virtualfish.readthedocs.io/en/latest/install.html#customizing-your-fish-prompt + if set -q VIRTUAL_ENV + echo -n -s (set_color -b blue white) "(" (basename "$VIRTUAL_ENV") ")" (set_color normal) " " end end -- cgit From 5611602e544abe6d8ad35f459a814f20172aec9c Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Thu, 24 Aug 2023 11:43:05 +0200 Subject: Added git tag abbreviation --- config/fish/config.fish | 1 + 1 file changed, 1 insertion(+) (limited to 'config/fish') diff --git a/config/fish/config.fish b/config/fish/config.fish index 1953bb9..1aea8c3 100644 --- a/config/fish/config.fish +++ b/config/fish/config.fish @@ -148,6 +148,7 @@ if status is-interactive abbr grv 'git remote -v' abbr gra 'git remote add' abbr gb 'git branch' + abbr gt 'git tag' function gpa set -f branch "$argv[-1]" # if branch not specified, get current branch -- cgit