Some fish functions
This commit is contained in:
@@ -5,15 +5,15 @@ if status is-login
|
||||
exec startx -- -keeptty
|
||||
end
|
||||
end
|
||||
set -x GPG_TTY=$(tty)
|
||||
set -x GPG_TTY (tty)
|
||||
|
||||
# }}} login to X #
|
||||
|
||||
# input
|
||||
xset r rate 200 60
|
||||
fish_vi_key_bindings
|
||||
set -x EDITOR /usr/bin/nvim
|
||||
set -x VISUAL /usr/bin/nvim
|
||||
set -x EDITOR nvim
|
||||
set -x VISUAL nvim
|
||||
|
||||
builtin cd $last_dir
|
||||
|
||||
@@ -30,3 +30,10 @@ source $spv_dir/src/api-keys.sh
|
||||
# set -U PATH /usr/local/sbin /usr/local/bin /usr/bin /usr/bin/site_perl /usr/bin/vendor_perl /usr/bin/core_perl /home/kevin/linux-config/scripts
|
||||
set -x PATH $PATH /home/kevin/linux-config/scripts
|
||||
set -x PASSWORD_STORE_CLIP_TIME 120
|
||||
|
||||
# fxn abbr's
|
||||
abbr ag "grep-aliases"
|
||||
abbr gcamp "git-amend-push"
|
||||
abbr hs "scan-history"
|
||||
abbr ut "unix-timestamp"
|
||||
abbr z "zathura-silent"
|
||||
|
||||
5
fish/.config/fish/functions/git-amend-push.fish
Normal file
5
fish/.config/fish/functions/git-amend-push.fish
Normal file
@@ -0,0 +1,5 @@
|
||||
function git-amend-push
|
||||
git add -A .
|
||||
and git commit --amend --no-edit -S
|
||||
and git push --force
|
||||
end
|
||||
@@ -1,4 +1,4 @@
|
||||
function gx
|
||||
function grep-aliases
|
||||
set key_aliases /home/kevin/linux-config/aliases/key_aliases
|
||||
grep $argv[1] $key_aliases
|
||||
end
|
||||
5
fish/.config/fish/functions/scan-history.fish
Normal file
5
fish/.config/fish/functions/scan-history.fish
Normal file
@@ -0,0 +1,5 @@
|
||||
function scan-history
|
||||
sudo systemctl start postgresql.service
|
||||
and $spv_dir/src/update-history.sh
|
||||
and cat $spv_dir/src/api/management/commands/update-history.log | tail -n 1
|
||||
end
|
||||
4
fish/.config/fish/functions/unix-timestamp.fish
Normal file
4
fish/.config/fish/functions/unix-timestamp.fish
Normal file
@@ -0,0 +1,4 @@
|
||||
# convert unix timestamp
|
||||
function unix-timestamp
|
||||
date -d @$argv[1]
|
||||
end
|
||||
@@ -1,2 +1,4 @@
|
||||
function vsnp
|
||||
set snips_dir "/home/kevin/.vim/plugged/vim-snippets/UltiSnips"
|
||||
echo $EDITOR $snips_dir/$argv[1]
|
||||
end
|
||||
|
||||
3
fish/.config/fish/functions/zathura-silent.fish
Normal file
3
fish/.config/fish/functions/zathura-silent.fish
Normal file
@@ -0,0 +1,3 @@
|
||||
function zathura-silent
|
||||
zathura $argv[1] > /dev/null 2>&1&
|
||||
end
|
||||
Reference in New Issue
Block a user