diff options
| author | 2022-04-10 20:19:16 -0400 | |
|---|---|---|
| committer | 2022-04-10 20:19:16 -0400 | |
| commit | 7f9f699cd71e06d7614ac947b4bdfccebed29360 (patch) | |
| tree | 9c1355f3e7bf6dbf72e1d295313522dea0ba0ead /dot_config/private_fish/functions | |
| parent | fish: use return instead of exit (diff) | |
this is cursed and I am not sorry
Diffstat (limited to '')
| -rw-r--r-- | dot_config/private_fish/functions/dot_.fish | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/dot_config/private_fish/functions/dot_.fish b/dot_config/private_fish/functions/dot_.fish new file mode 100644 index 0000000..93aca5a --- /dev/null +++ b/dot_config/private_fish/functions/dot_.fish @@ -0,0 +1,13 @@ +function . -a name + if ! test -n "$name"; return 255; end + set -e argv[1] + for path in . $PATH + if test -r $path/$name.fish + source $path/$name.fish $argv + return + else if test -r $path/$name + source $path/$name $argv + return + end + end +end |
