diff --git a/.config/fish/functions/cl.fish b/.config/fish/functions/cl.fish new file mode 100644 index 00000000..70c5f0da --- /dev/null +++ b/.config/fish/functions/cl.fish @@ -0,0 +1,5 @@ +function cl --wraps=cd --description 'cd, ls, clear' + cd $argv; or return 1 + clear + ls +end diff --git a/.config/fish/functions/fish_should_add_to_history.fish b/.config/fish/functions/fish_should_add_to_history.fish new file mode 100644 index 00000000..54d2dc8f --- /dev/null +++ b/.config/fish/functions/fish_should_add_to_history.fish @@ -0,0 +1,7 @@ +function fish_should_add_to_history + string match -q ' *' -- $argv; and return 1 + for cmd in ls clear + string match -qr "^$cmd" -- $argv; and return 1 + end + return 0 +end