mirror of
https://github.com/asdf-vm/asdf.git
synced 2024-11-15 09:38:16 -07:00
847ec73751
The use of `.` is deprecated in fish, unlike POSIX shells. We can avoid calling `psub` and pipe directly into source which does the same thing. https://fishshell.com/docs/current/cmds/source.html
16 lines
423 B
Fish
16 lines
423 B
Fish
|
|
# Add function wrapper so we can export variables
|
|
function asdf
|
|
set command $argv[1]
|
|
set -e argv[1]
|
|
|
|
switch "$command"
|
|
case "shell"
|
|
# source commands that need to export variables
|
|
command asdf export-shell-version fish $argv | source # asdf_allow: source
|
|
case '*'
|
|
# forward other commands to asdf script
|
|
command asdf "$command" $argv
|
|
end
|
|
end
|