summaryrefslogtreecommitdiff
path: root/.config/fish
diff options
context:
space:
mode:
Diffstat (limited to '.config/fish')
-rw-r--r--.config/fish/config.fish30
-rw-r--r--.config/fish/functions/dotfiles.fish3
-rw-r--r--.config/fish/functions/vim.fish3
3 files changed, 22 insertions, 14 deletions
diff --git a/.config/fish/config.fish b/.config/fish/config.fish
index 95657c5..35da1bb 100644
--- a/.config/fish/config.fish
+++ b/.config/fish/config.fish
@@ -1,14 +1,22 @@
-#!/bin/fish
+#
+# getchoo's config.fish
+#
-# defaults
-set -Ux VISUAL nvim
-set -Ux EDITOR nvim
-set -Ux GIT_PAGER moar
-set -Ux PAGER moar
-# abbrs
-abbr dotfiles 'git --git-dir=$HOME/.cfg/ --work-tree=$HOME'
-abbr orphans 'sudo pacman -Rns (pacman -Qtdq)'
+# add ~/.local/bin to path if the directory exists
+function add_local_bin
+ set -f dir "$HOME/.local/bin"
+ if test -e $dir; and not contains $dir $PATH
+ fish_add_path "$HOME/.local/bin"
+ end
+end
+add_local_bin
-# prompt
-starship init fish | source
+# default programs
+set -gx VISUAL nvim
+set -gx EDITOR nvim
+set -gx GPG_TTY (tty)
+
+# paths
+set -gx CARGO_HOME "$HOME/.local/share/cargo"
+set -gx RUSTUP_HOME "$HOME/.local/share/rustup"
diff --git a/.config/fish/functions/dotfiles.fish b/.config/fish/functions/dotfiles.fish
new file mode 100644
index 0000000..8873743
--- /dev/null
+++ b/.config/fish/functions/dotfiles.fish
@@ -0,0 +1,3 @@
+function dotfiles
+ git --git-dir=$HOME/.dotfiles/ --work-tree=$HOME $argv
+end
diff --git a/.config/fish/functions/vim.fish b/.config/fish/functions/vim.fish
deleted file mode 100644
index f0a542e..0000000
--- a/.config/fish/functions/vim.fish
+++ /dev/null
@@ -1,3 +0,0 @@
-function vim
- nvim $argv
-end