Visual Studio code
Editors are a religious thing. Many of us spend more time in an editor, or something with an edit feature, than anything else on the keyboard. For an accountant it might be the cell editor in a spreadsheet (which acts like an overgrown typewriter IMHO). For many office workers they have blurred the line between document layout, word processor and editor into something like Microsoft Word.
I’m a programmer and engineer though. Time I spend in either one generally means I am spending time futzing with fonts, layout or other glitter elements rather than provide the value of my skills which is raw content. I can have the most impact just by typing words. If I ignore the formatting the value of my contribution is not really diminished, it is just harder on the eyes. Formatting can be done by others or if your really want to read my terse concepts you can just read like all we had was typewriters. A light markdown like syntax is all I really need to bridge that gap though.
What I really should be typing is code. Could be in any number of languages and address any number of tasks, but one of the biggest ways I can contribute is by writing code. That brings me to the editor.
Editor
I have used so many editors over the years, and to be honest none of them have been effortless or fit like a glove. I have learned to love many of them and I have really found many displeasing. Many programmers will look down on the word “editor” and say I should be using an IDE (Integrated Development Environment). To them I will say it is just an editor with extra tooling.
You may have guessed that I come from either vi or emacs based on the above statement and other things I have written, and you would be right on both counts. I started to use vi in the late 80s when it was becoming more than a set of macros on top of ed (yes I also used ed). It was light weight, fast and would run everywhere I was. The command mode concept took some getting used to and got in the way occasionally, but I got a LOT done with vi over the years.
I tried emacs many times in the 80s and 90s. It was either too large for the systems I was on, or used keystrokes that collided with flow control or some other problem. I could have fixed some of these things, but didn’t really feel like it. In 2000 I found emacs supported some interesting debug features I really wanted and I switched. I have grown to really like emacs and use it literally ever day.
Over time I have tried different graphical editors to see if one is better, but none have measured up. Atom looked like it could be the logical successor to emacs if it wasn’t saddled with javascript (although that is also its super power given all the people that can contribute via that language). I never really gave it a fair chance early on as emacs was just there and worked. There where a number of others that looked really nice but ignored one or two things that were deal breakers for me.
Then came Visual Studio Code. It just worked out of the box. I started a Go project and it loaded tools and configured them for me. For Python it would coordinate the virtual environment among other things. It was easier to configure than emacs for the same functionality. I started to find myself using it for whole projects and being productive. Well mostly.
While vscode made a lot of things easier, it actually made a few things harder and some of those are essential.
Gripes
My first problem is sometimes is covers up what I need with a useless suggestion or document pop up. There is probably a keystroke to get rid of it, but requiring an action to see what I’m doing is a hurdle. The only saving grace is that the suggestions and docs are really good and I find myself using them. I give this problem a pass.
My second problem is that there are fewer key bindings for things. I have to use the mouse for things that should be simple keystrokes. That slows me down for more complex editing. This problem makes me mad enough that when it really gets in the way I almost always open up emacs to make the changes.
My third problem is that it opens up where I last closed it. If I’m in directory X, I want you to open in directory X. Opening up in directory Y is pointless because I’m not working on that right now. Stop assuming my workflow and habits. Do what I want at this moment, not what I did last time.
Finally, and maybe the fatal design flaw. You can’t print. Who builds anything with an edit feature and leaves out the basic concept of printing? Do they have some grudge against HP and are taking it out on the rest of us? Is this some environmental terrorism?
I have been involved with office build outs more than once and have run across architects who think programmers only need space for monitors, keyboards, mice and mugs/cans. When I ask where the occupant should open books or setup small devices they look at me like I have a third eye. Seriously! In one case they actually had all the bookcases removed, and we just had to order new ones after they left. Shhh, don’t tell them we violated their aesthetics.
Maybe it’s just because I’m old, but this shows a different view of how work gets done and makes me think maybe I shouldn’t be using vscode. I know there are extensions to print (I finally found one that isn’t kludgy, but getting to it is), but this should be in the File menu with a keyboard shortcut.
The future
I probably need to come to terms with vscode as it does seem to be the future for many years to come. I’m not going to run it on light weight environments or over some really crappy remote connections, but I still have emacs for those. I could make emacs do everything I want and get from vscode and I would be happy, but I’m not sure I have the time to futz with ELPA and mode configs.
Sigh.