Getting bash for Mac OS X

Problem

You want to get bash for your Mac, or you want to make sure you have the latest version.

Solution

According to Chet Ramey’s bash page (http://tiswww.tis.case.edu/~chet/bash/bashtop.html), Mac OS 10.2 (Jaguar) and newer ship with bash as /bin/sh. 10.4 (Tiger) has version 2.05b.0(1)-release (powerpc-apple-darwin8.0). There are also precompiled OS X packages of bash-2.05 available from many web sites. One such package is at HMUG. Bash for Darwin (the base for Mac OS X) is available from Fink or DarwinPorts.

Discussion

It is also possible to build a more recent version of bash from source, but this is recommended only for experienced users.

Get bash Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.