mirror of
https://github.com/gosticks/brew.git
synced 2026-10-05 15:06:54 +00:00
Merge pull request #11349 from davidxia/fish-path
fix: use recommended way of updating Fish shell $PATH
This commit is contained in:
@@ -98,7 +98,7 @@ describe Utils::Shell do
|
||||
ENV["SHELL"] = "/usr/local/bin/fish"
|
||||
ENV["fish_user_paths"] = "/some/path"
|
||||
expect(described_class.prepend_path_in_profile(path))
|
||||
.to eq("echo 'set -g fish_user_paths \"#{path}\" $fish_user_paths' >> #{shell_profile}")
|
||||
.to eq("echo 'fish_add_path #{path}' >> #{shell_profile}")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -78,7 +78,7 @@ module Utils
|
||||
when :csh, :tcsh
|
||||
"echo 'setenv PATH #{csh_quote(path)}:$PATH' >> #{profile}"
|
||||
when :fish
|
||||
"echo 'set -g fish_user_paths \"#{sh_quote(path)}\" $fish_user_paths' >> #{profile}"
|
||||
"echo 'fish_add_path #{sh_quote(path)}' >> #{profile}"
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user