Fish has exactly one user controlled config file which is named $HOME/.config/fish/config.fish by default. Fish also has an export command for compatibility with bash/zsh/sh but it just a thin wrapper around the fish form:
set -gx VAR value
As for bash aliases you have two choices: turn them into abbreviations (see the "abbr" command) or functions. In fish you can define a function with its "alias" command but that simply turns
alias myalias some_command --arg1 --arg2
into
function myalias; some_command --arg1 --arg2 $argv; end
As Glenn Jackman pointed "fish is not bash". It is not an improved bash. Switching to fish isn't hard but does require a little effort. I made the switch 13 months ago and think it is worth the effort.
2
fish
uses~/.config/fish/config.fish
for configuration. – DavidPostill – 2016-12-01T17:13:52.0603
fish is not bash. It's a different language with a different syntax. If there are functions or aliases you want to keep, you'll need to rewrite them. Be sure to read the tutorial
– glenn jackman – 2016-12-01T18:13:13.817Could you post me some examples? All I have in my .bash_profile are just some exports and some aliases. I would like to reuse them for fish! – sparkr – 2016-12-02T04:43:45.490
1
Possible duplicate of re-use '~/.profile` for Fish?
– Daniel Centore – 2018-01-04T05:17:52.537