Mandeep,

Have you also changed root’s shell to fish? Otherwise it will not read that 
config file.

If I may make a side comment, I wouldn’t recommend using fish as root’s shell. 
As much as I like fish, its code is not nearly as mature as bash or sh, so 
there’s a higher likelihood of bugs, which under root could have bad 
consequences. Also, I always prefer to make root’s environment as uncomfortable 
as possible, so that I’m not tempted to spend in it any time beyond the 
strictly necessary :)

—Diego


> On Mar 5, 2015, at 8:47 PM, Mandeep Sandhu <mandeepsandhu....@gmail.com> 
> wrote:
> 
> Hi All,
> 
> Pardon my noob-ish question.
> 
> I'm trying to add an alias which I can use running as myself or as
> root (via sudo).
> 
> I've added the alias in /etc/fish/config.fish. It works from me (as
> user), but doesn't when run under sudo.
> 
> How do I make the alias work under sudo?
> 
> Thanks,
> -mandeep
> 
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming The Go Parallel Website, sponsored
> by Intel and developed in partnership with Slashdot Media, is your hub for all
> things parallel software development, from weekly thought leadership blogs to
> news, videos, case studies, tutorials and more. Take a look and join the 
> conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> Fish-users mailing list
> Fish-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/fish-users


------------------------------------------------------------------------------
Dive into the World of Parallel Programming The Go Parallel Website, sponsored
by Intel and developed in partnership with Slashdot Media, is your hub for all
things parallel software development, from weekly thought leadership blogs to
news, videos, case studies, tutorials and more. Take a look and join the 
conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Fish-users mailing list
Fish-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to