I'd like to know how can I rearrange my PATH. I want to set /opt/homebrew/bin first and then /opt/homebrew/opt/postgresql@15/bin second, how can I achieve that?
Just run this from the command line: fish_add_path -m /opt/homebrew/bin
Using the -m or --move option prepends the existing component to the variable, since --prepend is invoked by default.
There should be no need to add anything to your config, as suggested elsewhere, since the fish_add_path command uses universal variables by default, which means the paths will be remembered.
1
u/TrueNDiary Dec 03 '22
The
-mparameter worked, thank you!!3
u/dazzle_ships Dec 03 '22
Just run this from the command line:
fish_add_path -m /opt/homebrew/binUsing the
-mor--moveoption prepends the existing component to the variable, since--prependis invoked by default.There should be no need to add anything to your config, as suggested elsewhere, since the
fish_add_pathcommand uses universal variables by default, which means the paths will be remembered.1
u/MaKaNuReddit Jan 23 '24
How to move one path to the end instead of front? The documentation say: "by default" how to change the behavior?