DEV Community

Cover image for Why TextMate 2 is My Favorite Code Editor for Mac (Part I)

Why TextMate 2 is My Favorite Code Editor for Mac (Part I)

davidmles profile image David Morales Originally published at davidmles.Medium Updated on ・6 min read

For many years I have been developing web applications. I’m usually faithful to an editor because I like to get to know it and all its features in order to be more productive.

I am currently developing with Ruby on Rails, and my favorite editor is TextMate 2. In this article, I will explain my reasons for this by comparing it with other well-known editors.

File browser

In TextMate, the file browser is on the right by default. That seemed strange to me at first, but then I started to feel comfortable because I write the code from left to right, as if it were a notebook, and having the file browser on the right helps me focus on the code.

File browser in TextMate 2

The look and feel is very Mac-style. It uses the same icons as the Finder, including the arrows next to each directory. In fact, when you enter a directory there is an animation, just like the system. It even hides hidden files by default, it’s the native macOS experience.

In Sublime Text, the look-and-feel is personalized. A very pleasing grayscale is used, with very similar behavior to native macOS, including the animation when entering directories. It shows hidden files by default.

File browser in Sublime Text 3

In Atom the customization goes further, losing the animation when entering directories and opting for a more minimalist display, using a dark mode throughout the editor. Hidden files are also displayed by default.

File Browser in Atom

Visual Studio Code completely customizes the interface as well. It does not have animation in directories, and the icons are colored, but minimalist at the same time. It also splits the browser in two, separating the entire file tree from the open files.

File browser in Visual Studio Code

Interesting to note that on the left there is a vertical bar with shortcuts to the essential functions of the editor, replacing the file browser when clicking on each one.

Brackets does not use icons, but it replaces them with something interesting: it highlights the extension of the files. There is no animation for directories either.

File browser in Brackets


The main difference between TextMate and the others is that TextMate is a native application for macOS only, and this is noticeable in the configuration.

Configuration window in TextMate 2

As you can see, TextMate displays a classic configuration window, where the most common extensions can be installed from the Bundles tab. In addition to these, there are others that can be downloaded and installed with a double-click, like Safari extensions. Older bundles, however, must be downloaded as a ZIP file and installed manually in a specific directory.

In addition to the configuration window, a file called .tm_properties can be configured, which can be in the personal directory or the directory of each project. To find out what to configure in this file you need to search for shared settings in GitHub, but there is no base template to customize. I imagine that Mac’s simplicity philosophy has been applied to this application so that those who are truly interested will have to dig around to configure advanced features.

In my case, I have only configured the ignored directories for searches, as seen in the following screenshot.

Configuring ignored directories in TextMate 2

In Sublime Text 3 a dedicated configuration editor opens, where on the left you can see a template with the default settings, and on the right you can overwrite them to customize. It is a very developer friendly way to configure the editor, having all the supported options available.

Configuration in Sublime Text 3

To install new packages, this editor has a package manager, which is installed the first time you access it. Then there is the option to install packages, which displays a list of available packages, installable by just selecting them.

Package control in Sublime Text 3

Atom has a mixed way to configure from the two previous editors. On the one hand, it shows some tabs to group the most important options, where they can be easily and visually customized.

Configuration in Atom

On the other hand, there is a search engine for packages and themes, which shows a list sorted by downloads. Clicking the Install button installs a particular package, and it is ready to use, no need to restart the editor.

Packages installer in Atom

The configuration in Visual Studio Code can be done in the same way as in Atom. On the one hand, there is a template with the available options, customizable on the right.

Configuration in Visual Studio Code

And on the other hand, there is an extension search engine. After installing, you have to restart the editor, traditional in Microsoft :)

Extensions marketplace in Visual Studio Code

Brackets uses the same approach as Atom and Visual Studio Code to configure options.

Brackets configuration

Same case for installing extensions. An extension can also be installed by dragging the ZIP file to the window or by specifying a URL. The editor must be reloaded after installing or uninstalling.

Extension manager in Brackets

Memory consumption

When I develop, I usually have two open browsers with several tabs, the code editor, the application server running, the code repository application, a messaging application, the email application, iTunes, and so on. Memory consumption should be optimized, because the code editor, despite being the most important tool in my work, is technically another function of the chain of programs open in my day-to-day. And if we add big applications, we’ll soon run out of memory.

For this test I will have only two tabs open:
One with a Ruby on Rails controller, of about 300 lines of code
A small ERB template of 18 lines of code

TextMate 2 is a macOS native application and exclusive to this operating system. Perhaps this is why it is well optimized and consumes very few resources.

Memory consumption with TextMate 2

As you can see, it takes only 61MB

Sublime Text 3, being also a native application of macOS (although not exclusive), has a reasonably optimized consumption, as seen below.

Memory consumption with Sublime Text 3

It consumes almost the same than TextMate 2, and sometimes without doing anything, just by changing the focus to the application, it takes around 111 MB, but then it stabilizes again at 77 MB.

Atom makes a difference. This application is not native but uses the multi-platform Electron framework. This framework uses Node.js, and we already know that Javascript is not too memory-friendly.

Memory consumption with Atom

A total of 415 MB consumed. It may not seem much, but compared to the previous editors it is a very significant difference.

Visual Studio Code also uses the same framework as Atom: Electron, ensuring a similar memory consumption.

Memory consumption with Visual Studio Code

But surprisingly, the consumption is a little lower than Atom: 384 MB. And although they share the base, the features have been developed by different teams, naturally.

Brackets is also a multi-platform application developed in HTML, CSS, and Javascript, and like the other multi-platform editors, that penalizes memory consumption.

Memory consumption with Brackets

The processes sum up 334 MB, very much in line with the editors of its style.

I continue analyzing the details of syntax highlighting and file type detection in the next article of this series.

Discussion (0)

Editor guide