Live data from Hacker News

Toward a “modern” Emacs

lwn.net

261–270 of 539 posts

Re: Toward a “modern” Emacs

#261
post #64

Earlier quoted context omitted.

> It is widely used for a staggering array of tasks. Is it? What area are you in? In my hobbyist, college, and industry experience I've never seen anyone use emacs for anything. I have seen Vim (or at least vim bindings) a few times, but I only know of emacs from older unix discussions online. Edit: Looking through stack overflow developer surveys, emacs use is in 16th place for editor popularity at ~4.5% usage, but…

Meanwhile, I’m always amazed how, on HN threads about Emacs, people talk about preferring the Vi family of editors. When I installed Linux on my computer two decades ago and had to learn *nix, my own (totally subjective) impression was that the Vi family was regarded as clunky and half-obsolete, about as much of a pain as editing in ed. As I began to contribute to the Free Software community, most of the other people…

I know I fell into it because I originally learnt UNIX on shitty XENIX servers which were basically AT&T SVR4 on x86. The internet and Linux weren't around then.

Later on I had to work with a number of different versions of different UNIX platforms on a daily basis (Tru64, Solaris, HP-UX, AIX) as well as multiple varieties of Linux, and vi was a common denominator on all of them.

Re: Toward a “modern” Emacs

#262

Earlier quoted context omitted.

this could sway me, as a novice, whats the mininum amount of steps (from necessary packages to install to actual inline math output o screen) to demonstrate this?

First, the proper way would be to use the appropriate mode for LaTeX (auctex). It has a keybinding. I don't use that mode, though, do I can't tell you how to set it up. I use org-mode, which lets you embed LaTeX formulae. I use this often, but surprisingly am not seeing anything in my Emacs config for this, so it may work out of the box. You do need some packages installed on your machine (dvipng, latex, etc). I alre…

thanks, that worked, I was down the auctex rabbit hole, and got stuck on a 'cannot load file... cdlatex' or some such...

C-c C-x C-l worked out of box!

Weird, once I have C-cxl'ed a fragment to rendered latex, and the C-cc'ed back to monospace, I am no longer able to insert superscript and subscript symbols, and it complains about cdlatex-superscript or cdlatex-sub-superscript...

Re: Toward a “modern” Emacs

#263

Earlier quoted context omitted.

First, the proper way would be to use the appropriate mode for LaTeX (auctex). It has a keybinding. I don't use that mode, though, do I can't tell you how to set it up. I use org-mode, which lets you embed LaTeX formulae. I use this often, but surprisingly am not seeing anything in my Emacs config for this, so it may work out of the box. You do need some packages installed on your machine (dvipng, latex, etc). I alre…

thanks, that worked, I was down the auctex rabbit hole, and got stuck on a 'cannot load file... cdlatex' or some such... C-c C-x C-l worked out of box! Weird, once I have C-cxl'ed a fragment to rendered latex, and the C-cc'ed back to monospace, I am no longer able to insert superscript and subscript symbols, and it complains about cdlatex-superscript or cdlatex-sub-superscript...

cdlatex likely is very useful if you plan to edit a lot of formulae. org has its own org-cdlatex minor mode (also needs effort to set up).

Re: Toward a “modern” Emacs

#264
post #227
post #166

Earlier quoted context omitted.

I will check it out in 10 years if it's still around. In the mean time I have actual work I need to get done.

> In the mean time I have actual work I need to get done. That's probably how most VS Code users feel about learning Emacs after reading about it on HN :)

I doubt they have had 20 years of using to it though.

Re: Toward a “modern” Emacs

#265

Earlier quoted context omitted.

I think adopting cua-mode as the default would go a long way towards reducing the initial friction for new users. Most of the time when I try to get people to adopt emacs, they abandon it because it feels like a huge task to relearn basic text manipulation. They never get to actually see what makes emacs good because they don't feel compelled to get past the initial bump.

But here's the question: If Emacs defaulted to CUA, how many of those people would get to see Emacs's goodness? CUA alone doesn't get you there. To do most of the things that make Emacs stand out involves a fair amount of learning (and possibly customizing). You have to put in some amount of effort before you get its benefits. While I certainly don't mind making simple things easier (e.g. CUA mode), I also see that d…

I don't understand why Emacs needs customisation to be useful. If it's not useful without customisation, why not ship a default 'customisation' that makes it at least somewhat useful to start with.

Re: Toward a “modern” Emacs

#266
post #28

I don’t know. I read the whole article and it seems the suggestions boil down to emacs needing to be more “modern” by defaulting to dark mode, making color theming easier, changing right click behavior, the menus, and changing the shortcuts. And the author of the article would like the development process to be more “modern.” Emacs is one of the most successful text editors of all time if not the most successful. It…

It's over 40 years old but it has fewer and fewer users younger than that. VS code is rapidly taking over it's niche and without modernization, of many kinds, emacs will die out in a generation.

> "VS code is rapidly taking over it's niche"

For comparison of numbers and growth rate: VS Code was new in April 2015, had a claimed 2.6 Million active monthly users in Nov 2017[1], became the most popular editor in StackOverflow's user survey in 2018[2] with 34% of respondants and again in 2019 with 50% of respondants, to a claimed 11 million users in 2020[3]. Its codebase has been forked 16,000 times[4].

In 5 years, VS Code has gained more users than the population of Switzerland, than the population of London, than Uber has drivers. I'm not suggesting Emacs ought to chase maximum popularity, but if there was any feeling that "the editor / IDE market was saturated" or "there was no demand for editors", that doesn't seem accurate.

[1] https://vscode-eastus.azurewebsites.net/blogs/2017/11/16/con... - (VS Code has telemetry built in, so Microsoft has some accurate idea of numbers, even if they still have the incentive to hype them up a bit).

[2] https://en.wikipedia.org/wiki/Visual_Studio_Code#Reception

[3] https://code.visualstudio.com/blogs/2020/06/09/go-extension

[4] https://github.com/microsoft/vscode

Re: Toward a “modern” Emacs

#267
post #26

Earlier quoted context omitted.

A lot of things are different without being better. Before ctrl-x/Ctrl-v became the standard for Cut/paste, it was Ctrl-del/Ctrl-insert in many dos and early Windows editors - which makes a lot more mnemonic sense. It’s better to standardize on something, but that something isn’t necessarily better and is often worse.

ctrl x/c/v is best because you can do it with your left hand while your right hand is using the mouse.

Yes! Exactly!

Re: Toward a “modern” Emacs

#268

Earlier quoted context omitted.

Personally, out of those I've only used Ctrl-R in the terminal. I just use the Home/End keys to navigate to the start/end of lines. I was actually surprised to read that Ctrl-E and Ctrl-A would do that. I usually expect Ctrl-A to select all, and don't really expect anything from Ctrl-E. (Though, I'd be surprised if home/end didn't work in Emacs, I'm just saying I've never used those readline keybinds).

> I just use the Home/End keys to navigate to the start/end of lines. If true, my guess is these were added to the shells recently (e.g. last 15 years). When I started using Linux (in the 2000's), these keybindings didn't work. It was Ctrl-A and Ctrl-E. I'd love to do a survey to see how many shell users use these vs Home/End.

I'm pretty sure the number of shell users has grown exponentially in recent years. I wouldn't be surprised if most users wouldn't know them.

However, the more one uses the shell, knowing those emacs shortcuts really helps (not just Ctrl+A, but also going forward or back one word). Especially on a show connection.

Re: Toward a “modern” Emacs

#269
post #155

Earlier quoted context omitted.

When you've been warned the world will end and ~~notepad~~ VS code will take over for 50 years you tend to become blase about the whole thing. Emacs has a steep learning curve and that's good. You need a moat to keep the barbarians from destroying your kingdom.

> Emacs has a steep learning curve and that's good. You need a moat to keep the barbarians from destroying your kingdom. Most of the emacs community radiates that same attitude, which is one reason it stays where it is and doesn't flourish.

Yes, it's wonderful the community is small and technically capable.

Re: Toward a “modern” Emacs

#270

Earlier quoted context omitted.

> If someone is not willing to learn how to enable CUA mode in the config file, then it is highly unlikely they will ever learn to use the features that make Emacs salient. I think that’s uncharitable. For a newbie low on confidence it’s often death by a thousand (paper) cuts: CUA mode, Surprising undo model, How to download packages, How do I enable fringes/margins, Windows-vs-frames, etc. Each small change has a co…

> Surprising undo model I tend to get surprised by this complaint - especially in the article where undo-tree was recommended as an alternative. Both the Emacs undo and undo-tree are "surprising" models in that very few standard editors support anything beyond the most basics. Personally, I've not had trouble with Emacs's undo (beyond it not visualizing it). Switching to undo-tree may be OK, but it's still surprising…

> Although I personally don't recommend it, but have you heard of Customize in Emacs?

I have, I've tried it, and it's terrible compared to virtually any other editor's equivalent for editing preferences/settings. It's super hard to navigate and search, it's difficult to figure out the terminology if you don't already know it, it's unclear how various settings affect one another, and IIRC it can actually make changes to your configuration file that conflict with editing it in any other way. To be fair, I am not a regular Emacs user, but getting sucked into the insanely frustrating tar pit of Customize made Emacs seem far more inscrutable to me for years.

If I could suggest just one change to make Emacs feel more "modern," it would be to entirely redo the Customize section to make it behave more like VS Code's preference system: one single page with collapsible headings, clear descriptions, and perhaps a super-top-level "behavior" control that makes batch changes to make Emacs more comfortable for users coming from different editors (e.g., choosing between a Canonical Emacs mode, Vim mode, or CUA mode). It doesn't have to try to cover every possible setting -- just hit the top several dozen and then say "for everything else, there's Lisp".

> Vim is also beginner hostile, so the beginner hostility really isn't the reason for Emacs's low usage.

This strikes me as half-correct, as someone who's made serious attempts with both of these editors. They're both difficult for beginners to get used to, but once you get over the initial learning hump, Vim was always much easier for me to tweak and configure. That may sound nuts, but editing .vimrc feels like editing an INI file, and at least in my experience, Vim's plugins are much better behaved when it comes to not stomping on one another. Every attempt I've made at getting serious with Emacs has ended in spending hours trying to get two or three extensions I want to use to play nicely with each other; with Vim (or VS Code), this almost never happens.

I've long suspected Emacs's greatest strength is also its greatest liability: you can do almost anything with it if you learn Emacs Lisp, but it often feels like you must learn Emacs Lisp to do almost anything with it.

> Most people new to, say, Visual Studio don't start with "How do I download plugins".

Not to pile on with the other reply, but, well: editors like Visual Studio Code, Atom, Panic's new Mac-only editor Nova, and even Sublime Text to a degree actually make plugins front and center. It's a very different approach than what Emacs and Vim have historically taken, but I think it's contributed greatly to their mindshare. VS Code in particular goes out of its way to recommend plugins to you based on the files that you've recently edited.

Post reply on HN