Attention: This page contains partner and advertising links. Therefore this page is to be understood entirety as an advertisement!
I use my Shell in a very high frequency. Some years ago I switched from the default Terminal.app to the free and open source alternative iTerm2. Unfortenately its not possible to set a default Shell in macOS at all so here an overview for the ways I tried to install iTerm2 as a replacement for Terminal.app.
Since I work a lot with React Native it drove me crazy that the launchPackager.command
was always opened with the default Terminal.app. To fix this, you can just hit the Get Info
context menu for any file that ends with .command
. The you can just head to the "Open with" section and hit the "Change all" button to use iTerm2 to open all files with the type .command
.
A shorter way to do this with a single file is by just pressing the Alt (⎇) key while the Open with
is visible. This will change the Open with
menu item with Always open with
.
iTerm2 is also able to register itself as default url handler in the Finder.app. To do so, just open the settings, go to "Profile" and select the url schema you want to register. iTerm2 will the ask you if you really want to overwrite the default scheme.
Another solution is the PreferencePaneRCDefaultApp from rubicode. With RCDefaultApp its possible to change every default application for any file type. The hardest part is basically to find all the file types you want to change. In my screenshot I changed the default application from Terminal.app to iTerm2 for the file type com.apple.terminal.session
.