Updating my text editor

14 Mar 2018 | programming, opinion, misc

The text editor is likely the software in which programmers (and those who sell themselves like ones, i.e. myself) spend the most time, thus it is vital that the tool of choice is up to the job. However, choice of the code editor is somewhat controversial.

In the core software engineering classes we had religious battles over which one should use; some preferred vim, some swore by Atom, and some were using RStudio, because “C is not that different from R, and it has latex support”.

As ever, I had a strong opinion on the matter as well.

Vim and emacs made my programming less efficient than it should have been. They are great tools, and can work wonders, but the steep learning curve and some features of “more modern” text editors made me avoid them on my personal computers (although I do use vim on the workstations without the GUI and it is quite awesome).

On the other hand, editors like Atom made me feel like I was using a browser - good for watching porn, and wasting time, but not too efficient for anything else. I’ve tried Atom in its early days and was severely disappointed. It would freeze when opening large projects, crash while updating, and cause more problems then it solved, and I’d experience input lag on even the smallest projects such as editing this blog. The larger projects such as torch would seldom even start up.

Sublime was a nice middle ground - it was lightning fast due to the native C++ implementation, and it had a plethora of plugins (provided you installed package control) and code editing features that made my life easy enough, and since they were implemented in python easily modifiable as well. The only real problem with Sublime was the initial setup time to get things where I want them. And the fact that you had to do it on every new computer, and it never ended up feeling quite the same. There have been workarounds for such issues such as unofficial Dropbox sync, but I found that would reload my editor every time my dropbox synced (which itself was handled in a very weird fashion on Linux). And if I wanted to use it on the computer where I didn’t have my personal dropbox synced (i.e. department provided workstation), … I guess I could script things? One other silly thing is that it was a closed source - paid for application. For some reason, I grew more and more fond of the idea of having my basic setup open-sourced and platform independent, and if possible, free.

Last summer, while working at MS, I needed something with simple text capabilities. Visual Studio/ReSharper combo was great for working with C#, but doing basic text editing was still easier to do in a text editor. Setting up sublime seemed like a major pain, because a) my license was paid for by another company, and b) it would take a while to set it up to work with my new environment (i.e. not developing python/lua anymore). Notepad++ was annoying as I used a Linux VM and it wouldn’t be transferable. I decided to support the local guys and installed VS Code not expecting much. It worked really well out of the box and had the support for everything that I needed, including an automatic switch to sublime key bindings. It was a bit slower on startup than sublime, but it didn’t feel like a porn watching tool, which is a big plus. I’ve pushed “dabble with VS Code” on my stack and forgot about it for a while.

Two weeks ago, while waiting for a couple of TB of videos to download, I figured, it’s as good of a time as ever to “dabble with VS Code”. Again, setup was straightforward enough on both my Linux workstation and Apple laptop. I installed the recommended plugins for the type of work that I am doing, and decided to try it exclusively until the end of the month, and see whether it is worth switching to. Here is the initial opinion:

Setup

I’ve been using the latest setup extensively for the last 20ish days for the following tasks:

  1. pytorch development: minor contributions and bugfixes to the pytorch repo
  2. maintenance of some legacy Lua code (torch relics)
  3. work on my own pytorch and caffe2 projects
  4. this blog
  5. editing .tex documents

I’ve used it on the latest macOS, Ubuntu 17.10 and latest Fedora. To find the complete list of plugins, look at the bottom of the post.

The good

The bad

Verdict

It’s too early to say, but I think this one is a keeper. I learned to love it and started to lean towards it as my main editor. It doesn’t mean that I’ll get rid of sublime, however VS code just became my go-to editor. It really is that good.


List of plugins at the time of writing:


Older · View Archive (12)

The sweetest kill

Ironically, I was listening to Sweetest Kill by Broken Social Scene, while I found today’s xkcd, and subsequently read the article on the Great Boston Molases Flood

Newer

March challenge: dictionary words

A challenge for March was to find and use a new word every day. It was a fun one, and almost certainly a useful one as well. I used both the dictionary (Oxford or Webster Pocket - whatever was closer), and Merriam-Webster’s word of the day feature.