Batteries included with Emacs

360 points19
Mikeb8515 hours ago

Honestly, I never really had that much love for Emacs until relatively recently. I've always dabbled due to it generally having good support for most languages (including esoteric ones) but recently I got into it a lot more due to the fact that many of the new-ish OSS editors but Emacs has always been there and likely will always be there.

A few years back I got into Atom quite a bit since it checked all the boxes: extensible, open source, and it was very nice. Then VSCode killed it. And it seems more and more that VSCode is taking over, all the while inserting more proprietary code to the point where half the 'big' plugins don't work on Codium, only the proprietary MS distribution.

So I got back into Emacs but really worked on my environment. Stopped dabbling and started just forcing myself to use it. And it's honestly amazing. It checks off every box available in VSCode and more. And it's nice knowing that it'll always be there. I'm not against proprietary software per-se, but I definitely don't have a lot of trust in Microsoft.

throw1092014 hours ago

One of the (several) unfortunate things about Atom being killed by VSCode was that its extension model was much closer to that of Emacs - everything ran in the main editor process - far more flexible than VSCode, but also with the mass-market appeal of JavaScript.

(yeah, that model led to poor performance, but afaict that's a combination of (a) just JS things and (b) not putting any effort into the design)

> I definitely don't have a lot of trust in Microsoft.

Very wise, given the user-hostile stuff they've been doing in Windows recently...

smallnamespace12 hours ago

> (a) just JS things and (b) not putting any effort into the design

This feels a bit self-contradictory, since one might argue a properly designed extension API must include process isolation, so naively-written extensions can't mess up the main loop. VS Code extensions are also in JS.

This is the same problem that, say, preemptive multitasking solves, and why Windows 3.1 crashed much more than '95 and XP.

rvieira11 hours ago

I'm also a recent Emacs enthusiast. Many many years ago, I never felt productive with the navigation and keys.

Then, recently, I _really_ wanted to try org and thought "I'll force myself to use it". I started with Evil mode and Doom. I was blown away tbh. What I thought to be an "old" tool that would slow me down, is actually a massive booster (and fun!). My personal experience, of course.

rolandog3 hours ago

I had a very similar experience, but I started with plain Emacs, and little by little adding what I needed. I was afraid of getting something really bloated, or not understanding how it all bundles together. I think it has paid off a bit, but the learning curve has been steep.

Spivak5 hours ago

Evil/Doom never really clicked for me and I went back to Neovim because of it. There were always gotcha's or packages that didn't have evil support and the when the walls broke down it was kinda clunky. Now that you can script Vim with Lua (or Python/Ruby) I don't really think I care too much about Emacs' infinite extensibility.

quotemstr14 hours ago

And thanks to recent developments in cross-editor infrastructure projects like tree-sitter and LSP, editors like VSCode, Emacs, Sublime Tex, and even public nuisances like vim can all advance at the same time and benefit from each other's development work in areas where the editors aren't differentiated.

We're very close to a world in which we don't have N implementations of finding the start of a C function or figuring out what parts of a Python buffer are keywords.

pronik11 hours ago

Somehow, Microsoft managed to invent LSP for VSCode and then abandon some parts of it just a couple of years later -- e.g. python language server is dead, pylance is there instead, closed source, VSCode-specific and with prohibitive license. Most language plugins in VSCode don't use LSP anymore IIRC.

pitaj7 hours ago

While it may be true that pylance is closed source and vscode specific, pyright[1] is MIT. Pylance does appear to still be a language server as well. As far as I know, most language plugins still use LSP, including Typescript/Javascript, Rust, and Go.


Spivak5 hours ago

Pyright is the best thing I've ever added to my Python workflow. It's nuts how productive you can be with a good type checker and completions.

nocman6 hours ago

"public nuisances like vim"

Others here seem to have taken this as tongue-in-cheek. On the first read I took it as "I think vim is ridiculous". I'm honestly curious to know which it is (or if both are inaccurate).

quotemstr5 hours ago

Of course it's tongue in cheek. Vim is venerable high quality software that a lot of people love. Emacs people dunking on vim (and vice versa) is just an old traditional joke with no actual animus behind it.

lc9er14 hours ago

> even public nuisances like vim.

I love vim (err… Neovim), and this was great.

agumonkey14 hours ago

we all love vim, especially to mock it absurdly

BeetleB10 hours ago

Which flavor of vi do you use? Spacemacs or Doom?

(Edit: Yes, this is a joke)

sg474 hours ago

Vim is dn addiction. Difficult to quit

smitty1e13 hours ago

Spacemacs is bee's knees.

ripe15 hours ago

For people who ask, "why use text-only editors like vim or Emacs, when I can use a full GUI IDE?":

One of the reasons I haven't seen mentioned much is: I'm a touch typist, and I hate having to switch between mouse and keyboard! I have to take my attention off the screen. Slows me down. Disturbs my concentration.

With Emacs, I can work for hours without ever having to hunt for the mouse, or without even having a mouse plugged in. That's particularly nice for using my Ubuntu laptop on a lap desk, leaning back in my armchair. The best mouse is no mouse at all.

Yes, I know many IDEs have shortcut keys for some commands, but the basic assumption with GUI applications is that you have a mouse. Even if you learn the shortcuts, somehow you always end up having to use the mouse for some common task, e.g., to select a paragraph. That's why I never got to like a GUI IDE, despite having had to use Eclipse for years.

sirsuki10 hours ago

I found I am unique, I never learned to touch type but at the same time reaching for a mouse really slows me down. I realized years into using Vim that the reason I love it so much is that I can do all my editing from the keyboard and because it is a deterministic state machine (modal) I can have a mental copy of the editor running in my head while I'm not looking at the screen. This is important to me because I look at my hands while typing. When I use GUI editors like VSCode it pops up all kinds of fancy bells and whistles that when I return my eyes to the screen it no longer matches the mental model I had in my head and I have to do a huge context switch to re-sync; just like how I have to context switch when I reach for the mouse. Am I the only one has this method of typing/editing? Praise the creators for Vim and Emacs editors.

hibbelig1 hour ago

All these friendly gooey things want to help you by popping up this kind of stuff. But luckily, some of them let you turn it off.

I've told IntelliJ and Eclipse and VSCode to please stop popping up suggestions, and let me type Ctrl+space to summon them.

Aaaah. Much better.

radarsat155 minutes ago

Drives me crazy that these types of programs always want to fill in the closing bracket for you. Like, as soon as you type an opening bracket, it sticks a closing bracket there. Completely interrupts my train of thought, why would I want the editor to assume it knows what I want and write things for me? Maddening. Especially something that messes with my internal thought process around the syntax "tree" that I'm trying to work out. I always disable it, but I have no idea how people put up with that. In Emacs on the other hand, it just highlights the matching bracket for you, so you easily know to type when you need it. Accomplishes the exact same goal without being so intrusive. I think there's a UX lesson to be learned there.

psandersen2 hours ago

I also find moving hand to mouse is a really frustrating context switch, so I ended up getting a roller mouse ( to use along with my main mouse. The idea is for lots of small things my hands stay at the keyboard but my thumbs can move the mouse so I don't incur a context switch.

mellavora2 hours ago

You are unique, but not in this respect. I write the same way, with a mental model of the editor state an integral part of the coding process.

ziftface3 hours ago

I'm afraid you are the only one

derekjdanserl8 hours ago

Honestly stunned. Thanks for sharing.

lawn15 hours ago

I find it amazing how common it is for programmers to not be touch typists (I mean typing without looking at the keys). Like, isn't that something you pick up by the sheer amount of keyboard time?

2ion32 minutes ago

It is simple, really: There are also many piano players who cannot make confident and accurate movements on the keyboard without looking at their hands! My process learning how to type on a computer keyboard without looking was very much like the process I experienced while working on my piano skills over the years: You graduate from fumbling with your hands and exhausting switching between looking at your hands and the sheet music to sight reading to playing with your eyes closed (if you want to). Though a lot of advanced players can and do play without sheet music and sight reading at all, interestingly, a lot of those players then keep looking at their hands instead! because the music progression is strictly following their mental model of the piece.

lokedhs2 hours ago

I don't touch type in the sense that I don't hold my fingers on the home row the way I was taught back in school. My home position for my right hand is shifted by one column, and I never use the little finger for typing. My hands move around the kit more than what a touch typist would be do.

However, I still type easily without looking at the keyboard, and I'm about as fast as the average typist, perhaps faster.

Could I speed up more? Possibly, but I don't feel that I'm slowed down by typing speed, and I find my way to type better when one uses a lot of special characters, as is common when doing programming and accessing Emacs keys.

mabub2414 hours ago

Most people get by with pseudo-touch typing. They have most of the speed down, and look down at the keyboard occasionally, but they do not have the accuracy that is displayed in true touch-typing.

lakkal8 hours ago

That describes me. I described it once as 'highly advanced hunt-and-peck'. I did learn to tough-type in school, but I didn't touch a computer until the following year and simply forgot it all. That was 40+ years ago. I get by well enough.

bitexploder13 hours ago

That sort of blows my mind. How can you not learn to touch type? It will take you a month at most and it greatly improves life at a keyboard.

garretraziel11 hours ago
zelphirkalt9 hours ago
ReleaseCandidat1 hour ago

> It will take you a month at most

I always gave up after about a week, I've tried it twice or three times during the last 25 years. Like always, good (fast) enough beats perfection. And I'm a mathematician and programmer because I'm lazy :D

pronik11 hours ago
phist_mcgee12 hours ago
Keyframe2 hours ago

I can type at warp 9, but never in my 30+ years with various computers and keyboards have I felt lack of typing speed or lack of laser focus on screen would be a drag on peogramming 'speed' or abilities even. However, it is a bit odd for someone spending few years behind keyboard not to pick up touch typing.. prime example being MDs.

edgyquant14 hours ago

I can type without looking but I still have trouble placing my fingers over the keyboard in the right initial place so I’ll often start a little off and I type so fast that I’ll type half a dozen characters before I realize and have to correct.

Mikeb8513 hours ago

Most keyboards have a little raised bump on the F and J keys ;)

wrycoder12 hours ago
Mikeb8514 hours ago

I'm not that old (30's) but we were forced into learning how to touch-type throughout grade-school. Pretty much any white-collar work requires it. Getting through university basically requires it (even humanities courses; good luck writing long essays without it). It's shocking that anyone who went through school in a developed country can't touch-type.

epolanski11 hours ago

Which developed countries have courses in school to learn touch typing?

I have never, ever heard about it.

Edit: by touch typing I mean having your index fingers on fj and from there using ALL keys without ever leaving the starting position, and yes that includes shift, alt and control and special characters.

I know very few people who are really touch typists (I am a proficient one), and I don't believe for a second people are taught touch typings, it's a skill that requires consistent training.

mabster2 hours ago

We had a touch typing class in the mid nineties in South Africa.

I told my teacher I don't need to touch type (I could already use a keyboard from tons of programming) so she said if I could beat her I could sit it out. I beat her and she kept up her end of the bargain.

However years later I wish I had just sucked up my pride and learnt it because I had to eventually anyway. It wasn't so useful for programming, but it's great for text (emails, etc.).

I find it interesting that in your view most people aren't touch typist. My experience (now in Australia) is that most people touch type. Although, there does seem to be a spectrum of purity. e.g. my fingers always remain on the home rows, but I use left shift for all capitals except Q, A, Z (when I'm using QWERTY).

Mikeb8511 hours ago

Well I grew up in Canada. We had generic 'computer lab' classes (don't remember which subject it was associated with for most of those years) from kindergarten to grade 12. Touch typing was definitely drilled into our brains throughout.

And of course it's not a 'course'. 'Reading' and 'writing' weren't courses, but you learn them regardless. It's too basic to be a course. It's just stuff we learned.

Edit - the format for schooling here is for the first 6/7 years you have a single teacher all day long. That teacher teaches you every subject. And that included several trips to the computer lab per week. The next 6 years of schooling had 'courses' split up by teacher and time slots, but again, computer lab time in some of those courses. There was also a required course called 'CALM' (Career and life management I think) which included a very strong computer lab component. There were also CS-ish electives (equivalent to shop classes) where you learned CS, albeit at a very basic level. And this was during an era where most people didn't have computers at home... So computer labs were always open after school hours.

Edit 2 - Anyhow, a lil random. But being able to touch-type at a specific speed on a test program was required to pass CALM and it was required for high-school graduation. Some kids could pass and then forget it all, but in general the entire schooling system here involves computers enough that most people can touch-type.

Edit 3 - My partner had a similar educational upbringing, despite being born under communism. Hell, she can touch-type multiple keyboard layouts (for other languages) on a US keyboard despite not being technically inclined...

Avshalom10 hours ago

How old are you? so I'm 35, USAian, and I had typing as a specific bit of course work (can't remember the program names) in elementary school (so 92-95ish?) and there was a class when I was a freshman in highschool (2000) that was 50% typing (different program, also don't remember the name) and 50% word/excel.

I'd absolutely believe that a lot of us on HN grew up in the narrow slice of time when computers were novel enough that people thought they should teach typing specifically, before that time: too niche; after that time: it's assumed we already know

the_only_law11 hours ago

It was included as part of the curriculum in certain classes I had in middle school.

As with most things in my education, most people including myself just put in minimal effort, to get the grade (which touch typing didn’t really effect, as it was not part of any homework, quizzes, tests, etc.) and after a few years you never had to see it again.

macintux9 hours ago

I’m 50, and I took a typewriter course in high school because it seemed obvious that keyboarding skills would be useful, although computers themselves were still somewhat niche.

bombcar10 hours ago

It was called “computer class” but most of it was touch typing (you had to type with a cardboard box over your hands).

gpderetta11 hours ago

I learned touch typing as an exchange student in an US high school in the late '90s.

Mikeb8510 hours ago

> Edit: by touch typing I mean having your index fingers on fj and from there using ALL keys without ever leaving the starting position, and yes that includes shift, alt and control and special characters.

Yes, we were taught that all throughout school... Is the US school system really that shit? I'm curious where your scepticism is coming from?

Like really, I didn't know a single kid in university who couldn't consistently type 60 wpm. 40 wpm was literally required to pass high school, pretty slow, but not something you can do staring at the keyboard punching keys one by one. The kids who were really good at it were touching 100wpm. I could get highs of 80-90.

I can count on one hand the amount of people I've met who can't touch-type...

themadturk7 hours ago

I suppose it depends on your definition of touch typing. Back in the early 70s, before many people had heard of personal computers, I was planning a career in journalism. I had to learn my way around a keyboard, so I took a quarter of high school typing. It didn’t teach me to “touch type” in the sense of achieving 100 word per minute or whatever, but it was the solid foundation I needed for typing in college, in my (too brief) journalism career, in office work and systems admin work. I’m reasonably fast, and I don’t always look at the keyboard, and no one has ever complained about it.

BlueTemplar13 hours ago

You're assuming that most of the writing is done on computers - but depending on the discipline - it isn't : computers aren't nowhere nearly good enough to compete with paper / chalk (/ even whiteboard !) when it comes to mathematics-heavy domains.

Mikeb8513 hours ago

Pure maths is a pretty small niche. The vast majority of while collar work, university students, etc..., definitely type and use computers constantly.

zdragnar14 hours ago

I'm a touch typist, but emacs chords always bothered me. I feel much more content switching to mouse or track pad for things like switching tabs, picking files from a file tree to copy / paste or duplicate or whatever, etc.

That said, being a programmer and not touch typing definitely sounds odd to me as well

ced13 hours ago

emacs chords always bothered me

I got carpal tunnels a few years back from emacs, which forced me to try . I like it a lot, it's more sensibly designed. I've found it a pain to install though...

smitty1e13 hours ago

Spacemacs has saved me.

convolvatron13 hours ago

unfortunately I can only really work for long stretches on a kinesis split keyboard - with the modifiers all the on the thumb. if they would finally make a bluetooth one maybe that wouldn't be so bad.

xhevahir12 hours ago
someguydave12 hours ago

remapping caps lock to control helped me with emacs chords

epolanski11 hours ago

Touch typing isn't about writing without looking at the keys, that's something that pretty much every dev I know does. It's about writing in an efficient way that minimizes finger travel, and zeroes palm and writ movement.

There's a reason F and J have bumps on them, or why we have two shifts, etc.

For anyone interested into relearning how to type efficiently I want to recommend this free website full of tutorials and exercises:

macintux9 hours ago

> There's a reason F and J have bumps on them

Actually that’s a regression. At one point some keyboards (Apple IIRC) put the bumps on D and K, which made it much easier to notice when your hands were misplaced.

It’s easier to notice that the wrong finger has the bump than noticing that no finger has the bump beneath it.

michael-ax7 hours ago

to operate and use a tui like emacs with confidence and start typing at the speed of thought:

consider putting a photo of your keyboard next to your screen and painting the keyboard a nice uniform black.

your body-mind's intelligence will swiftly learn to position your hands and coordinate your/its fingers without adding things to unlearn later.

the photo of your keyboard near where you are focusing when looking at the screen makes a huge difference, one could start with just that.

Y_Y12 hours ago

Yes, but I often work with different keyboards. The place I live has a couple of different stupid local variations, and then if I have an Anglosphere keyboard it's 50-50 between UK and US. Sometimes I change the "layout" and type as if I'm on a different keyboard, but usually the keys don't even physically match up. Then there are different types of keyboard, from super-compact to full numpad monsters and from chiclet to hefty mechanical, and then there's my shitty touchscreen phone.

I'd love to be able to type from muscle memory, but the keyboards keep changing!

ramraj076 hours ago

I actually like it being a touch typist? Using the mouse gives me more movement and I like it. From my observation, there also seems to be a very high correlation between touch typing and carpel tunnel as well.

fhd214 hours ago

I literally trained the correct technique as a child because I was so into computers. I'd argue children today are far less exposed to keyboards than people (well, nerds) my age were.

edgyquant13 hours ago

Maybe but I’ve typing since I was a kid on a Windows 95 and I still only know the gist of the keyboard and have to look down and correct myself every minute or so, so I don’t that’s they only reason. I actually think that typing without looking isn’t as important as people used to say it was for speed.

wizzwizz413 hours ago
FpUser3 hours ago

I was programming since 80s and had never managed to learn touch typing. I am a vegetable in this department. My fingers do remember some key sequences so when I press first key I could usually master the rest of the sequence without looking but then I have to look again.

I could probably put a gun to my head spend a month and learn it but I do not really feel it slowing down my programming (I spend more time thinking and drawing some skeletons) so I've never bothered.

b3morales14 hours ago

Also a keyboardist, and you can pry my emacs from my cold dead fingers, but I still think it would benefit from a bit more ability to incorporate platform-appropriate keyboard-driven GUI widgets/arbitrary drawing. For example, if the minibuffer could look like a regular GUI text field + a drop-down menu, or a floating command palette, I genuinely think it would be a nicer experience (and would make it "look more modern" which is not a terrible thing)¹. Similarly for the mode line and fringes. If some of the peripheral elements could be enabled to escape the "everything is a grid of characters" paradigm I think it would be a net positive.

¹I've tried mini-frame, and it's fine, but it's still just a utilitarian grid of text.

arkaic11 hours ago

On your last point, in terms of absolute speed, pointing your mouse to the paragraph and dragging to highlight is usually faster than the fussiness of multiple key presses and/or chord combos needed from a full keyboard setup. That is, unless you've macro'd a custom single key shortcut for just that particular action

tikhonj11 hours ago

Emacs has a standard shortcut for moving around in terms of paragraphs, so you don't need to customize anything. It's these semantic(ish) movement commands that really let keyboard navigation shine—moving around in terms of paragraphs, code blocks, matching delimiters is not only productive but also combines well with other commands and keyboard macros, which makes a lot of repetitive things easy to automate in Emacs but difficult anywhere else.

spicybright7 hours ago

I have no problem going keyboard to mouse, but mostly because I use a macbook with touchpad exclusively. Reaching my thumb down right below the space bar to use the mouse is really not a big deal.

arkaic11 hours ago

+ and basically I would generalize this across to all the common actions people typically use that are often easier with a mouse. And can even be faster, even with the extra hand travel to the mouse.

chlorion14 hours ago

It's worth mentioning that Emacs is not a text-only editor, but is able to function in a text only environment if configured to. I think many people never consider giving Emacs a shot because they think it's purely a terminal based program.

Modern Emacs can be (and mostly is) compiled with GTK support and features a GTK interface, but can be launched in text-mode with a command line argument. If you don't mind using bleeding edge versions, there is a branch called "PGTK" that allows the GTK interface to run natively on Wayland!

Mikeb8513 hours ago

> If you don't mind using bleeding edge versions, there is a branch called "PGTK" that allows the GTK interface to run natively on Wayland!

The two biggest Linux distros (Ubuntu and Fedora) are Wayland by default now. And the 'standard' Emacs distribution you install through the Software 'store' in both is GTK (which of course works). Wayland support isn't really a big deal anymore. I haven't come across any apps that don't work on Wayland.

d_tr13 hours ago

Yeah, it is GTK but not pure GTK! It uses X11 drawing calls for some elements so it needs XWayland on Wayland. Pure GTK might be coming with Emacs 28 by the way.

vegai_3 hours ago

At least on Sway (with the scaling settings I use), fonts are a bit crap (blurry) on xwayland and perfect on native Wayland.

__jem7 hours ago

IntelliJ has a M-x equivalent and IdeaVim covers text editing. I literally never touch my mouse when using the IDE. I really don't think this is a compelling argument.

xhevahir12 hours ago

I just started using VS Code a lot last weekend and I didn't find myself using my trackpad much. The Vim plugin, whatever it's called, allowed me to do the same things I do in Vim itself. I can't speak to the Emacs emulation, though, now that I think about it.

epolanski11 hours ago

To add to this: yes, full blown IDEs have shortcuts but they are hard to explore, counter-intuitive and hard to extend.

spicybright7 hours ago

I think JetBrains has a great system to it.

cmd+shift+a opens a command palette with every possible command in the IDE. It matches as you type the name of an action, and every action has a keybinding shown to the right (if it exists).

Every relevant button generally has keyboard shortcuts right on them.

And pressing cmd+e opens a list of gui interactions you've made so you can repeat them (things like focusing buffers, clicking on a file in the project file tree, etc.)

Basically, if you know cmd+shift+a, you're golden for learning commands and key shortcuts.

In comparison, emacs/vim are pretty awful. I've done a few tutorials of each and while I could have spent more time learning them, JetBrains makes it stupid easy to start learning the editor.

pville5 hours ago

Alt-x does the very same in Emacs. Every available command with tab completion and with the keyboard shortcut listed. I think showing the shortcut is new.

If you are not familiar what a particular command does you can use C-h f <function-name> to open the help page.

I think Emacs is really easy to learn after you get a handle of the navigation keys. Which you might already be familiar with from shell.

gjvc5 hours ago

shift-shift brings up the same window, albeit with different prompts.

FpUser3 hours ago

Never mind being "touch typist" I completely suck at typing in general. I think my cat could do a better job.

Still I hardly ever use mouse when using IDE's like Visual Studio C++ coding for example. It has shortcuts for everything.

luxcem35 minutes ago

I used emacs for a number of years and recently switched to doom-emacs as a base configuration. I got tired up of trying to fit together many packages and I found that doom is highly customizable but with sane and polished default.

I can recommend it to anyone that tried emacs but didn't like it.

justinhj17 hours ago

Great to see lists like these. I’m a long time Emacs user and recently learned to use neovim. I made the same mistake many new Emacs users make in that I installed a lot of plugins at once and lost control of the editor. Only by installing packages incrementally after you have discovered a real need, can you keep mentally on top of what your editor is capable of.

bloopernova13 hours ago

This is a very good point. I first tried to jump in Emacs by using Spacemacs, and was overwhelmed trying to manage the fairly huge and complex init.el that Spacemacs produces. I also had lots of trouble before realizing that Spacemacs and vanilla Emacs package configurations should really be treated as separate and not mixed together.

I'm sure if I went back to Spacemacs now, I'd understand things a whole lot better, but as a new user, it was far too much to figure out at once.

So I went Vanilla, and haven't looked back. I do think that there should be some more articles out there like "so you've decided to try Emacs? Here's what to do beyond opening and saving documents". With a heavy emphasis on, as you said, incrementally adding to your configuration. Something like "here's why you split your config file into 2, with automatic changes going into one file, and manual going into another" followed by "here's use-package" and "if you want to X, here are Y packages that do it" with comparisons between each different way. But broken down into small chunks so things can be done incrementally.

epolanski11 hours ago

I second this, I started with spacemacs, and then reinstalled clean emacs to get a good grasp of it.

chewxy1 hour ago

I'm quite annoyed. I was working on a minor-mode because I tire of having to switch to my browser for asciiflow. Reading this article, it turns out artist-mode is built in to stock emacs. And it's quite good, better than anything I could build.

Discoverability problem? You don't say?

submeta16 hours ago

After spending endless hours in learning the ins and outs of Emacs and starting to learn Elisp, I come to realize that Emacs‘ tinkering-to-doing ratio is too high. I need tools that get out of my way. Emacs can get a hobby or an obsession. If you have nothing else to do, fine, spend your time sharpening the saw instead of cutting wood.

I turned to VS Code + PyCharm for coding. And use Emacs for editing text only. And for that, it is excellent.

What I love about Emacs most is the macro recorder. Whenever I have to transform text, I record my steps in Emacs‘ macro recorder and replay the steps. That’s like magic. I wouldn‘t even bother writing a Python script for these one-off transformations.

BeetleB13 hours ago

> I come to realize that Emacs‘ tinkering-to-doing ratio is too high.

You are in full control of how much tinkering you do, though. Strange to blame a tool for this.

tom_13 hours ago

But most of the things you do require a certain amount of tinkering, even basic stuff like setting up C indentation, making Emacs not use tabs, and configuring keyboard shortcuts - especially in the early days, when you might not quite understand how things fit together.

Compare and contrast with Visual Studio Code, which has a much smoother onboarding experience.

BeetleB13 hours ago

Agreed about the onboarding experience. However, the person I was replying to seems quite well versed in Emacs.

ordu7 hours ago

Much more strange when a tool blames its users for their unsatisfying experiences. It is tool is made for user, not the other way.

inetsee15 hours ago

I love emacs because of org-mode. I have sometimes wondered whether emacs can do something I have often wanted. I write poetry. If you write with pencil on paper the edit marks (line through, move text, insert) let you see the evolution of a work. It's hard to get the same effect with a text editor. After reading this web post I went searching for "emacs edit history" and I discovered "undo-tree". This is a perfect functionality for my use case, and another reason for me to love emacs.

clircle10 hours ago

BTW, the author is using the Modus Operandi theme for Emacs. It's really easy on the eyes (high contrast) and comprehensive. Oh, and it's beautiful.

Shout out to Prot who maintains it.

justinhj10 hours ago

I use it too, highly recommended

NeutralForest9 hours ago

True, Prot is the man

animal_spirits17 hours ago

Sometimes I wish I initially spent my time learning emacs. Vim has been great to me. I don't value programming workflows as much as I used to so I'm not going through that steep learning curve again

dotancohen17 hours ago

  > Sometimes I wish I initially spent my time learning emacs. Vim has been great to me.
Try SpaceMacs, or even just Evil. I've found that Emacs (the text editor environment) and VIM (the language for interfacing with a text editor environment) skillsets are actually complimentary and together form a terrific text editor.
srcreigh17 hours ago

If spacemacs or evil seem too inauthentic or complicated, I suggest boon-mode. It's a very simple, modular, minimal modal editing package with verbs and motions.

jb199115 hours ago

And if you like modal editing but want to stick to a more emacs-centric interaction, there is God mode which I eventually found to be better than evil if you are working solely within emacs.

hvgk17 hours ago

Conversely I feel I wasted my time learning emacs and moved to vim eventually. I also only religiously use a subset of vim functionality which is fulfilled by most of the vi equivalent editors. This turned into a massive advantage for me as I spent most of my career dotting around random Unix and Linux machines doing admin work. Vi derivative is always there and the muscle memory was ready to go.

One of the key things I found though is that I learned to compose tools outside of vi rather than rely on the editor functionality. This was applicable to much larger problem domains than just editing. The Unix philosophy of using lots of small well defined things to solve problems applies to editing text.

cyberbanjo16 hours ago

FWIW if I can ssh I can use emacs tramp to edit remotely, if there's latency lag, it seems similar to using local editor.

spicybright7 hours ago

I've done SSHFS to fairly good success for this too.

kovek15 hours ago

I really like to use code-server instead

zingar16 hours ago

I think you get a lot just out of knowing modal editing. Sometimes I don't even realise what is emacs and what is vim because of evil keybindings.

rthomas617 hours ago

You may like Doom Emacs. It has really really good Vim keybindings. Some people like Spacemacs too, but I found it too bloated and too abstracted (hard to fix when it breaks).

I still find myself reaching for Vim when I want to just write a simple script. Emacs, VS Code, etc. can just be too much sometimes.

zingar16 hours ago

I had a pretty full featured vim setup (creaking under the weight of all those plugins) and then switched to spacemacs. You're exactly right that debugging was a pain sometimes, but once I started to figure out what everything was, I wanted to replicate everything I had in vim.

I realised that if I'd started minimal I would have reinvented so many of the spacemacs wheels, but done it worse.

Spacemacs could do with being slightly more user friendly. It gives you a lot of friendliness already, but to prevent people from being frightened off by emacs' formidable reputation it really needs to "work" out of the box. For me that would be one click install and a reasonable suite of IDE-like features for working with a given language pre-configured. That would include scripting to install the command line tools that they shell out to, e.g. ag or rg.

dfinninger17 hours ago

Have you looked into emacsclient? If you have emacs running you can connect to it in the terminal so that there’s (practically) no startup time.

It replaced vim on the cli for me.

Y_Y12 hours ago

> I still find myself reaching for Vim when I want to just write a simple script. Emacs, VS Code, etc. can just be too much sometimes.

I used to do this too. What stopped me was that I often use emacs as a terminal multiplexer with vterm, and it becomes super difficult to control vim if you have evil-mode capturing those same inputs. In the end oh-my-zsh (more crappy bloat like spacemacs which I love to bits) has an alias called "e" which will open a file for editing in your current emacs.

(If only it worked through docker! Or maybe it does and I just don't understand TRAMP well enough yet.)

hwestiii11 hours ago

As far as I know, pure vanilla emacs from GNU comes with multiple vi emulations. I’ve been using viper for 20 years. It’s the only reason I use emacs at all. I had a co-worker many years ago who swore by emacs, but I found the key bindings completely counterintuitive having learned vi while getting my degree. Having made that discovery I was off to the races with emacs, and have never looked back.

emodendroket2 hours ago

Emacs is really just a beautiful refutation of the "Unix philosophy" that programs should only ever do one specialized thing. It's a kitchen-sink tool and it's very useful, and has been for decades.

mlaretallack17 hours ago

I really respect people who can use emacs (and vim, vi etc...) they wiz around doing allsorts and make it look effortless.

The only reason I have not tried is I seem to spend most of my time thinking about the change, and the time saved is easily wiped out by the time taked to re-write the line 5 times.

reddit_clone15 hours ago

You don't really have to. Try DoomEmacs or something similar, very little tinkering needed to get going.

gjvc5 hours ago and were the two "game-changers" for me getting me comfortable in emacs.

timonoko6 hours ago

BTW. You do not need typing skills with Emacs, because it has an autocomplete. And it is subject and writer specific. Firstly you load some text containing words you want to use in another buffer and then you bind M-X hippie-expand to some convenient key. I use (global-set-key (kbd "å") 'hippie-expand) because Swedish å is useless in Finnish keyboard.

This works even better with languages with varying form and spelling. Finnish Android autocomplete gives mostly annoying and mispelled suggestions, but in Emacs you can use your own writings as the sublime storage of words.

jb199115 hours ago

Amazing that I have not used emacs in years but I wanted to see this artist mode with my own eyes, so I opened it and was surprised I could still remember how to get all around with the m-x commands... my muscle memory even remembered the combo to exit emacs correctly, and even as I type this, I couldn't tell you what that key combo is! It's all in my finger muscles' memory. Incredible.

pantulis14 hours ago

This is what Emacs does to your brain. Dont know if that's a good or a bad thing, mind you.

My first serious Emacs engagement happened in 1996, with XEmacs. Then it became my editor of choice for basically two decades. I can confidently say that I can open your Emacs setup and manage my way around it (unless you happen to be an evil-mode infidel, that is).

umanwizard13 hours ago

C-x C-c

Blackthorn17 hours ago

Oh damn, I had no idea about undo-in-region. That's so convenient and it comes with Emacs stock. Wish I knew about that years ago.

bloopernova14 hours ago

I've been using Emacs for about 4 years now, and some of the stuff on this list was news to me. Thank you, OP, for sharing this; I found it useful!

Kototama14 hours ago

Same, more than 10 years and I really should have known M-\ earlier :-) (or remembered it, I think I read about it earlier).

The thing is with Emacs, you can really optimize every key stroke if you want, but usually I'm too busy using it to program so I optimize the workflow only time to time.

pama12 hours ago

Some of the very recently upgraded batteries in standard emacs include describe-bindings (C-h b gives a neatly organized, foldable output that greatly enhances discoverability) and emoji-insert that uses a neat selection interface.

Y_Y12 hours ago

For discoverability I love using helm with M-x (or SPC-SPC). I just think of a function I might like to call, like "git fetch" or "sort lines" or "render latex inline" or anything else, and pretty quickly I can figure out what it's called and what its shortcut is for next time. I take for granted that it exists.

pama10 hours ago

Helm is great and I still use it occasionally even after I recently transitioned to using orderless, marginalia, consult, vertico, etc. for most things like that. C-h b has become my recent goto for inspecting the keybindings on various modes; I used to do C-h m, but the new interface of describe-bindings is neat.

wrycoder12 hours ago

326 lines long!

entropie17 hours ago

I use emacs for over a decade now. It took like 2 years and 3 serious approaches to get into it. Now it feels like home.

I didn't know about SelectiveUndo. Nice.

adriancr14 hours ago

This is what I like about emacs see a few nifty things, easily add shortcuts and integrate, (selective-mode is useful for an outline of a file).

Power comes from being able to customize - add a easy shortcut to show outline, add another to back to non-outlined. Then use these to jump around code.

cfjgvjh7 hours ago

As someone that has always wanted to try stock emacs, this kind of a breakdown is appreciated. I know the individual systems aren't all that complex but when you're new to almost all of them it gets overwhelming quickly.

teddyh18 hours ago

I think many Vim users look at Emacs and go “Hmm, Emacs is a bit more clunky when I use Emacs to do the exact same things I do in Vim. Therefore, I’ll stick to Vim.”

notreallyserio17 hours ago

"It'd take me longer to figure out how to use emacs than it would to just do what I want in vim, and I'm really just trying to get to retirement before I lose my mind."

lqet17 hours ago

As a vim user, I mostly look at this article and think, "Hmm, Emacs seems to include an artists mode for drawing ASCII images. I need a text editor. Therefore, I'll stick to vim."

dotancohen17 hours ago

That's how I felt until I started using org-mode.

I think that Org-mode is now the fourth piece of software on my never-gonna-give-you-up list, after VIM, GNU coreutils, and Anki. I seem to add one per decade.

drivers9916 hours ago

As a vi user, I got to artist mode and was wondering what keys you would press to draw rectangles and circles and how you would get out of it, but it doesn’t say.

User2317 hours ago

Then you definitely wouldn’t be interested in M-x tetris.

marcosdumay17 hours ago

Maybe M-x doctor could help, but maybe not...

Shared40416 hours ago

How does that make you feel?

alpaca12817 hours ago

And there's nothing wrong with that opinion. As long as the basics aren't covered I don't care about extra features.

For me Emacs fulfills the same purpose as Vim, but mostly in exactly the opposite way of how I want it. Some people prefer that, I don't. It's a great program, but not my cup of tea and so I don't use it. Vim does everything I need without annoying or distracting me, which is rare enough.

ByteJockey17 hours ago

I mean. Emacs has the ability to do basically what vim does. Evil mode is really nice (though I can never get used the = register evaluating elisp instead of vimscript).

What kills me about emacs is the startup time. Breaks my flow when I'm jumping around and need to edit something quickly.

Though I'll admit that doom provides a very nice environment for when I want to play around with some lisp.

tarboreus17 hours ago

Run Emacs as a server. Then open with emacsclient. Instant and you have access to the same process you've been using with all the buffers, etc.

emacs --daemon

emacsclient <fie>

Jtsummers16 hours ago

  emacs --daemon=<name>
  emacsclient -s <name>
Useful for when you have different contexts and want to separate them more cleanly.
FrenchyJiby10 hours ago

Absolutely worth it, but it needs mentioned that bundled in Emacs is a sytemd job for launching the server at user login(!!!):

    systemctl --user enable emacs.service  # For next login
    systemctl --user start emacs.service  # launches it just this once
This means I never have to even THINK "I should boot the editor", because it's already ready.

Add a keyboard shortcut for emacsclient and you're golden

cyberbanjo17 hours ago

Use emacsclient and don't close emacs server. Super fast startup (for emacs). There is a guide on emacswiki afaicr

a_e_k9 hours ago

I've had M-x emacs-uptime hit nearly 200 days before. It takes a little effort to get used to that style of working, but it's definitely handy once you do. (Also, I

    alias ec="emacsclient -n"
in my shell.)
clircle6 hours ago

I use vanilla Emacs with 145 packages and my startup time is 0.9 sec on a 6 y/o thinkpad. With deferred evaluation, there is no need to use a daemon.

michael-ax6 hours ago

emacsclient can also talk to multiple emacs-servers by name. this is awesome to keep different sets of buffers available.

also, there's zile.

ByteJockey6 hours ago

It's still not instantaneous like `vim .` is. Also it leaves me outside of my terminal. I know, I know, just don't leave emacs, but that's not how I work.

I appreciate the tip about zile though. That looks cool.

rthomas617 hours ago

Check out Doom Emacs for a fast startup time with no server.

ByteJockey12 hours ago

I mention using doom in the last line of the comment you responded to.

But, yeah. I use it for the start up time/vim compatibility out of the box.

tra317 hours ago

Check out evil mode. Makes emacs behave more like vi. Game changer for me.

RMPR12 hours ago

One of my pain points with evil mode (and with every vim emulation for that matter): it's often incomplete. To keep my fingers on the home row I use Alt to exit insert mode (:help i_META in neovim) but Alt- is already mapped to something in Emacs, and that's just painful.

b3morales16 hours ago

That inward-spiralling learning curve never ends. `selective-display' is my new trick for the day. Thanks!

meken7 hours ago

Last time I was coding, I used vim+tmux. I found terminal emulation in emacs slow and buggy.

I do always have a spacemacs window open, but I only use it for magit.

Scarbutt6 hours ago

FWIW, I use emacs exclusively inside tmux, starts in ~0.3ms for me with more than 40 external packages.

fermentation14 hours ago

I've always wanted to get into emacs, but I only have enough room in my life for a single set of keybinds, and vim has taken that spot. A lot of the emacs-for-vim-people projects are these huge distributions and when something breaks I have no idea how to fix it. Do any of you have a good resource for learning emacs from the ground up, but with vim keybinds?

throw1092014 hours ago

I started using vim before switching to emacs, and my experience was that just installing evil-mode and then picking up any normal emacs tutorial was enough - I skipped all of the editing specific stuff and got the interesting stuff from the rest. You might want to try that.

Actually, your question made me realize that the interesting part of vim is the modal editing interface, while the interesting part of emacs is everything but the text editing bits. So, focus on those.

Does that help, or have you already tried this?

acheron938314 hours ago

Honestly, to just get moving, installing Doom emacs and selecting evil mode during setup. The basic keybinds are all Vim then, works great for me with minimal headache.

dhersz9 hours ago

Is there a vim/tmux feature similar to pulse? I do lose my cursor sometimes when switching panes and I'd love to try something pulse-like to see if I like it.

fhd214 hours ago

Some cool stuff I had no idea exists! But I can't see anything I feel like picking up, I do like to keep it simple. I switched to Emacs after something like six years as a vim user, primarily for the more beginner friendly key bindings so my coworkers wouldn't get _too_ freaked out. Many of the navigation shortcuts work in most shells and even all text fields in macOS out of the box too!

I did implement all kinds of funky customisations at first, but in the last years I stuck mostly to what comes with Emacs, and customize over writing Elisp. I do some work in IntelliJ and Xcode out of necessity, but there's nothing quite as productive for me as vanilla Emacs and ansi-term. It's all just text - and mastering how to deal with text doesn't take that long, and is fairly universal.

One of my favourite and most trivial habits is to use forward/backward search extensively for navigating around a file.

worik14 hours ago

For me the killer aspect of Emacs (it applies even more to vi) is being able to use it in a terminal so being able to use it over a network connection.

I know X can export over a network connection, but text mode Emacs is much simpler and does not require X.

a_e_k9 hours ago

I once used a little netbook at a conference in Germany on a crowded wi-fi connection to edit using Emacs within a terminal SSH connection to a desktop in the western U.S.

It held up surprisingly well. The Emacs terminal display system dates from the days of low-baud terminal sessions and so decouples screen updates from the editing input. I.e., it's smart enough not to try to fully update the screen on every keystroke when the terminal connection is slow -- not unlike dropping video frames to keep up. So you can type ahead with some lag and know that it will bring the screen up-to-date as efficiently as possible whenever it can.

cbm-vic-208 hours ago

Emacs is older than X11.

dylan60417 hours ago

Batteries may be included, but some assembly is definitely required in learning all of the commands to make it useful.

I'm sure vim and emacs were great tools back when monochrome monitors were all that were available. But with modern UI IDEs and what not, I only use vim when need to make fast and dirty changes directly on the server. I do find all of things that can be done in emacs/vim quite impressive, but I'm also quite happy that it is not the tool I have to use because nothing else is available.

I do find myself getting environments backwards in my head though when flipping back and forth quickly. Like typing :wq in my IDE, or cmd-s in vim when prompts my terminal to save my session.

azalemeth9 hours ago

That text drawing mode is beautiful. Or of curiosity, entirely because my vim knowledge is far greater than that of Emacs, is there anything like it for vim, including two button mouse support?

stinos15 hours ago

Perhaps not the right thread, but: is there anything like 'follow mode' in other editors like Sublime Text/VSCode/Visual Studio editor? I'm now emulating that with e.g. 'new view into file' followed by manually scrolling. Having that autoamtic can be really handy.

Kessler8317 hours ago

Great article! I like the approach to focus on things that ship per default and take no time to learn! Also didn't know about undo in region!

rStar13 hours ago

emacs is like a musical instrument in program form. one is only limited by their creativity.

taeric10 hours ago

Very well done demos of some fun packages in emacs. Thanks!

baby18 hours ago

I’m wondering if a vscode in the terminal could ever exist.

dotancohen17 hours ago

That's like wondering if elephants could ever roam the depths of the oceans. If they did, they would no longer be elephants.

What specific features of vscode would you like to see in a terminal editor?

cmroanirgo15 hours ago

About 15yrs ago I had a nice vim vs vstudio competition with a friend. It started with "look what vim can do"... block select, block indent, bookmarks, etc Vstudio (& now /vscode) can do too. Vim was always slower (mainly bc the guy wasn't seasoned by 10yrs of it) to figure it out. The interesting thing is that vstudio has the same abilities, but for the really arcane stuff (which vim users take as why it's better), can be done too, but just more keystrokes. Lots of the everyday stuff is often the same or fewer keystrokes than vim. And you can always write a macro for edge cases.

So to me, the "win" of vstudio is the tiny command pallete that is used & the shortcuts are displayed in menus. (& everyone mentions the difficult hill to climb to learn emacs or vim by comparison).

The thing which will never work in terminal is ctrl-c and ctrl-v. (Macos covers this nicely by using cmd-... tho). It's a shame.

I actually use le editor in terminal, but am rather cramped using it. I consider learning vim or emacs once every few years... and go... nah, no thanks.

Eg. There are a few comments above about region undo. In vstudio it sounds ugly, but it's trivially easy. Press and hold undo (ctrl-z) and let key repeat until the block appears as you want. Select it, copy. Press and hold redo. Select area. Paste.

Tastes are different.

jorams14 hours ago

> The thing which will never work in terminal is ctrl-c and ctrl-v.

If you enable cua-mode in Emacs, C-c and C-v work perfectly fine as copy and paste. Even in the terminal.

> There are a few comments above about region undo. In vstudio it sounds ugly, but it's trivially easy. Press and hold undo (ctrl-z) and let key repeat until the block appears as you want. Select it, copy. Press and hold redo. Select area. Paste.

That works in practically every editor. The entire point of region undo is that it's faster and more convenient than doing it manually.

Eelongate12 hours ago

Elephants can walk underwater using their trunks as snorkels. Maybe they would be too buoyant for it in sea water. It seems a fair thing to wonder though.

baby17 hours ago

I’m not sure why not? Everything has a shortcut in vscode. And if it doesn’t you can use the command palette.

dotancohen16 hours ago

You might like VIM. In VIM everything has a shortcut as well.

In fact, in VIM, everything _is_ a shortcut.

baby13 hours ago
rgoulter7 hours ago With the disclaimer that I haven't tried it.. this tool aims at being a successor to nano.

lvass17 hours ago

There are many terminal web browsers.