Comment by chuckadams

3 days ago

> Defaults emacs ships with today are really good.

They're really not. It still defaults to opening a split window, still litters #foo# and foo~ files in the directory of whatever you're editing, and still comes with few language modes supported out of the box, let alone set up to automatically spawn and use LSP servers. Running a macro over a 10,000 line file is still incredibly slow on a 1-year old mac. Many common functions are still bound to chains of two or sometimes three keystrokes with multiple combinations of ctrl-keys and sometimes the mysterious ctrl-u prefix. Rebinding all the defaults is pretty much a given for any emacs power user. It's no wonder RMS ended up with RSI problems, because "emacs pinkie" is still very much a thing.

I miss emacs in a lot of ways, I used it for a good two dozen years starting in the 90's, but there's a reason I use IDEA Ultimate to write code now.

You may have two dozens years of emacs, but I fear you’ve not grasped the philosophy of emacs, if that is the list of complaints.

> split windows.

Why would I want a new window to replace the one I’m in. If I want to look at an info manual, I want it to start in a new window instead of the one that I’m looking it. My understanding is that there are main tasks and secondary tasks. Switching main tasks replace the current windows, starting secondary tasks pop up a new one. And those pops up are usually dismissed by typing q.

> still litters #foo# and foo~ files in the directory of whatever you're editing

Backup files and autosaved files are good. Especially if the edited file is not versioned. It’s the correct choice as some users are not programmers.

> few language modes

How many toolchain are installed on a newly installed OS? And major modes are not only for syntax.

> LSP servers

Eglot is built in and has a good set of default for current servers. But why should Emacs install stuff for me. It does not know how I want to install them.

> macro over a 10,000 lines

macros do run the full set of the commands as it would run in a normal invocation time the amount of repetition. And there are other approaches like an awk script that may be faster for your usecase.

> common functions…bound to chains of two…three keystrokes

Emacs have a lot of commands. And if you used something a lot, you can bind it to a more accessible bindings.

> mysterious ctrl-u prefix

If it’s mysterious after two dozen years, then I wonder if you ever give the manual a glance. It is for providing an argument to the command and it’s commonly used for providing an alternate behavior to the default one. Like ‘g’ is recompile in a compilation buffer and ‘ctrl-u g’ asks for the command to use for the new iteration instead of reusing the old one.

  • Nothing says "prompt interactively" like Ctrl-U. I mean, it literally stands for "universal argument", which is basically "do this command, but different". Defaulting to "insert four times" because why not? Mysterious :^)

    Like I said I used emacs for a quarter century, wrote quite a bit of elisp for doing my job, and I still miss some of those things, but I've made do with perl scripts. I still pop up emacs for quick edits now and again, but I long ago gave up trying to force it into the shape of a full-blown IDE.

  • > Backup files and autosaved files are good.

    Your parent wasn't saying they weren't. He just doesn't want them in the same directory. I've set up my config to dump all these in a dedicated directory.

> but there's a reason I use IDEA Ultimate to write code now.

IDEA is so painfully slow that while I have it paid by my company I cannot force myself to work in it for extended periods of time. And I say it being fully aware of Emacs's speed problems. Also, the limitation on "1 Window - 1 Project" is laughable in IDEA, as well as in VSCode.

  • IDEA can certainly get slow, but `esc 10000 c-x e` still means I'm hitting abort before it gets even close to done. I use multiple panes/windows in IDEA all the time, and it also supports opening tabs in new windows/frames.

    • I have just opened a 7k loc JS file in idea and I can observe for at least 2 seconds how syntax fontification and all the hints are applied and rendered. All of it on a macbook M4. It is not acceptable and also the slowest of any editor I've used.

      2 replies →

  • > the limitation on "1 Window - 1 Project" is laughable in IDEA

    There's no such limitation in IDEA. If your project consists of separate subprojects stored in subdirectories inside a single large directory, just open that directory in IDEA. Your subdirectories will work/look/feel like different projects, all within the same window, with global symbol search, support for attaching SQL resolution scopes (i.e. attaching different databases to different projects and/or paths within them and having correct autocomplete), etc.

    One of the things I work on is such a project built from a dozen separate subprojects, some of them written in Java, one in PHP, one in JS/node, one in TS/React, two in Go, one in Python. Plus the usual stuff like Markdown, HTML, CSS, SQL, etc. It all integrates very nicely within the same window.

    If they're stored in completely separate directories, and you want to combine them into a single window for some reason, it's still perfectly possible by attaching them as "modules" inside your project settings. It looks and feels exactly like the first case, even when projects are spread across the system.