Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

10.6: Install fish shell on an upgraded version of 10.6 UNIX
Snow Leopard only hintAll the cool kids are using fish (bash is so 90's!), so why can't I? Because it won't install on my copy of Snow Leopard, dang it. I spent the greater part of this weekend trying to figure out why fish didn't like me. Read this so you won't have to endure my pain.

Using MacPorts, typing port install fish wouldn't result in a working installation. The install kept asking for iconv, gettext, or whatnot. 64-bit/32-bit Unix apps don't play well together in Snow Leopard, and because I upgraded from Leopard, I needed to reinstall MacPorts to deal with it. Long and painful, indeed.

  1. Follow the directions on upgrading in this entry in the MacPorts wiki. The basic steps are:
    1. Save the list of installed ports: port installed > myports.txt
    2. Clean any partially completed builds: sudo port clean all (this will take a while!)
    3. Uninstall all installed ports: sudo port -f uninstall installed
    4. Browse myports.txt and install the ports that you actually want to use (as opposed to those that are only needed as dependencies) one by one, remembering to specify the appropriate variants: sudo port install portname +variant1 +variant2 ...
  2. Install fish: port install fish
  3. Make fish the default shell. Append opt/local/bin/fish to the /etc/shells file. Then open the Accounts System Preferences panel, unlock it, Control-click on your account picture and select Advanced Options. Set the Login Shell to opt/local/bin/fish.
Voila! Enjoy fish! For more on fish, check out this Ars Technica article, and this lwn.net article.

[robg adds: The above is a modified repost of this entry on the author's blog. I changed the layout and some of the wording for better integration with the macosxhints site, but none of the technical details were edited.]
    •    
  • Currently 2.13 / 5
  You rated: 4 / 5 (15 votes cast)
 
[7,038 views]  

10.6: Install fish shell on an upgraded version of 10.6 | 11 comments | Create New Account
Click here to return to the '10.6: Install fish shell on an upgraded version of 10.6' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.6: Install fish shell on an upgraded version of 10.6
Authored by: asmeurer on Nov 12, '09 08:09:37AM
fink install fish worked fine with 64-bit fink. You still have to do the third step above if you want to make /sw/bin/fish the default shell. Personally, I'm going to stick with bash, because some of the command competitions (such as for fink) do not seem to inherit into fish.

[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: operator207 on Nov 12, '09 08:20:46AM

All the cool kids? Heh, all the cool adults are using tcsh. ;) And not because it was the default shell on older OS X installs.



[ Reply to This | # ]
zsh
Authored by: SeanAhern on Nov 12, '09 09:26:30AM

Not to get into a religious war, but I've always considered zsh to be the superset of all the other shells. I graduated from tcsh to zsh. I believe zsh has all of the features that tcsh has and then some.



[ Reply to This | # ]
Wish
Authored by: renaultssoftware on Nov 23, '09 01:38:34PM

I would rather use wish (Tck & Tk) or X11.



[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: brh on Nov 12, '09 08:28:47AM

FWIW, fish was about the only one of my ports that survived my upgrade to 10.6… Still need to get this process done for all the rest of my ports though, grumble.



[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: everkleer80 on Nov 12, '09 09:44:57AM

I never really understood the difference between the different shells. Anyone know of a good page that shows a good comparison of the different shells?



[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: OverZealous on Nov 12, '09 11:24:13AM

Well, the fish website (linked above) has screenshots.

:-)



[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: scooby509 on Nov 15, '09 08:46:45PM

http://en.wikipedia.org/wiki/Comparison_of_computer_shells



[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: rexroof on Nov 12, '09 11:52:46AM

Looking at the screenshots it looks like a lot of it is meant to be for linux users.

as a unix veteran of 15 years or so, I used to spend a lot of time doing tricked out shell customizations, but these days I just stick to plain bash with just a handful of settings.



[ Reply to This | # ]
perl anyone?
Authored by: SOX on Nov 12, '09 02:52:56PM

Why would anyone want yet another shell syntax? If you need to write anything serious in shell you should be using perl, it's the optimal language for low level scripting. If you are not doing anything too complex, then bash and tcsh are easy enough. Fish has nothing on perl, so what's the point? (and don't say Python. Were talking about shell scripting and perl is basically shell scripting heaven.)



[ Reply to This | # ]
10.6: Install fish shell on an upgraded version of 10.6
Authored by: wfolta on Nov 15, '09 03:10:50PM

I ran into problems when I was attempting to upgrade some other software. One issue is if you need both 32-bit and 64-bit versions of a library. On Intel Mac's this is known as "Universal". ("Universal" used to mean both Intel and Motorola binaries, I believe.)

To force the second version to be installed, when you already have one -- which I could never do from a GUI -- try something like:

sudo /opt/local/bin/port -vf upgrade --enforce-variants libiconv +universal



[ Reply to This | # ]