Mac OS X is beautiful, but the Terminal UI and UX hurts – let’s fix it!

There are times when one has to drop back to the command line. But the default Terminal window on Mac OS is small, black and white and forces me to think about case sensitivity. Let’s make the Terminal window a bit more beautiful! I want mine to look like this:

  • Ocean Blue Theme
  • Some transparency
  • Not case sensitive
  • Nicely formatted folder listings
Terminal Window

Terminal Window

Configure the window

First let’s make Ocean the standard profile. Open a Terminal window and go to settings. Select “Ocean” and click “Standard”

Terminal Ocean

Terminal Ocean

Next, switch to the tab “Window” and set the columns to 160 and the rows to 50 to make the window bigger.
To get the transparency, select the background color and put opacity to 95%.

Fixing case sensitivity

By setting

set completion-ignore-case On
set show-all-if-ambiguous On

we achieve the following: when typing “cd Do” followed by TAB, the result will be

iMacRR:~ rene$ cd do
Documents/ Downloads/
iMacRR:~ rene$ cd Do

  1. No more case sensitivity! Even though “Documents” and “Downloads” both start with an uppercase “D”, I can now use a lower case “d”.
  2. Instead of beeping or not doing anything because of the ambiguity, the Terminal window now shows me a list of available matches.

Instead of setting the properties manually, we can create a text file named “.inputrc” and put it into the user home folder (Open Finder, press SHIFT+ALT+G and go to “~”).

Now the last change: format of the directory listing

When I type “ls“, I really mean “ls -lpFh“.

  • l: long list format (more overview)
  • p: write a slash if an entry is a folder (easier identification of folders)
  • F: show special characters if files can be executed, are symbolic links, etc.
  • h: show file size in sensible units (Megabytes, Kilobytes, …)

iMacRR:~ rene$ ls -lpFh
total 0
drwxr-xr-x   5 rene  staff   170B  8 Nov 13:53 Applications/
drwxr-xr-x@  5 rene  staff   170B  8 Nov 08:58 Applications (Parallels)/
-rwxr-xr-x   1 rene  staff    56M 26 Jan  2007 Basta!.pdf*
drwx——+ 13 rene  staff   442B  8 Nov 16:41 Desktop/
drwx——+ 14 rene  staff   476B  8 Nov 16:47 Documents/
drwx——+ 16 rene  staff   544B  8 Nov 16:32 Downloads/

In order to be able to only type “ls”, I create a file named “.bash_profile” in my home folder (Open Finder, press SHIFT+ALT+G and go to “~”). This is a text file with the content:

alias ls=’ls -lpFh’

You can download both files here. Happy command-lining.

Post Media Link