diff options
Diffstat (limited to 'dot_config/private_fish/functions')
| -rw-r--r-- | dot_config/private_fish/functions/autosource.fish | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/dot_config/private_fish/functions/autosource.fish b/dot_config/private_fish/functions/autosource.fish deleted file mode 100644 index c064218..0000000 --- a/dot_config/private_fish/functions/autosource.fish +++ /dev/null @@ -1,30 +0,0 @@ -set -q __fish_autosource_path -or set __fish_autosource_path $__fish_config_dir/plug - -# you must include '' for completions to work -set -q __fish_autosource_exts -or set __fish_autosource_exts .fish '' - -function autosource -S -d 'Source plugin' - for plug in $argv - for f in $__fish_autosource_path/$plug$__fish_autosource_exts - if test -f $f -a -r $f - source $f - break - end - end - end -end - -function __complete_autosource - for d in $__fish_autosource_path - set -l len (math (string length $d) + 2) # 1-index + / - for f in $d/**$__fish_autosource_exts - if test -f $f -a -r $f - echo $f | string sub -s $len - end - end - end | sort | uniq -end - -complete -c autosource -x -a "(__complete_autosource)" |
