What's new in Emacs 31.1

(masteringemacs.org)

146 points | by geospeck 21 hours ago

8 comments

  • kstrauser 18 hours ago
    Between treesitter and eglot (read: LSP), there’s not much from other editors I miss when using Emacs. I’ve been on a Zed kick for a while but I hear the call of the GNU. This may be the week I declare .emacs bankruptcy and start again with a clean setup, seeing how much of my old third-party config I can replace with builtins.
    • froh 25 minutes ago
      I infer you don't use magic?
    • wmedrano 5 hours ago
      Are there any Zed features you're going to miss? Is the AI notable?
      • kstrauser 5 hours ago
        Not really, no. Zed’s a fine editor and I have nothing but good to say about it. I just happen to prefer Emacs more. Its keystrokes are burned into my muscle memory. And because its config files are literally executable code, there’s nothing too crazy for Emacs. Can it do XYZ? Absolutely, if you tell it to!

        As to AI: Emacs continues to have zero built in. If you like it, though, it supports any agent you might want to use. I was highly amused the first time I wanted to use my own company’s agent and found it was already well-supported by a popular package.

        And honestly, Emacs + a coding agent = magic for anyone who wanted to use it but was intimidated by Elisp. “Hey Droid, tell Emacs to swap the command and option keys on my Mac.” “Ok, done!” It’s a ludicrously powerful combo.

        • ubercore 1 hour ago
          I went full circle on AI. For an in-editor experience, Zed is top notch. But I've found I actually prefer just to go back to claude code + Zed.
    • mickeyp 3 hours ago
      AI is very good at Emacs Lisp - esp GPT. So you'll have an easier time around today!
  • rtpg 10 hours ago
    Bit of a tangent but does anyone have good learning materials on doing things with Emacs Lisp beyond just staring at the source of packages?

    I have the Mastering Emacs book and read through most of it, which gives me a good idea for some stuff... but I really would like to have good ideas for the right kind of design patterns for common things.

    • rootnod3 5 hours ago
      All of Prot's packages[1] are really nicely designed imho.

      [1]: https://protesilaos.com/emacs/

      • sph 4 hours ago
        He’s also got a Youtube channel if you prefer to learn that way.
    • MarsIronPI 9 hours ago
      Have you read through the Emacs Lisp Intro and Elisp manuals in Info? The latter is especially helpful as a reference.
    • wmedrano 9 hours ago
      I started getting a little more into ELisp after reading The Land of Lisp, though its probably a bit basic. If I were to try to get better at ELisp through reading books/docs, I'd look into Common Lisp material.
  • bpye 3 hours ago
    Is there a better way to get started with Emacs than the built in tutorial? I've tried a couple times (due to increasing annoyance with VS Code), but have struggled to get to a point where I feel productive enough.
    • jmmv 6 minutes ago
      Start with Doom Emacs. I haven't felt the need to customize almost anything since I switched (from VSCode) 4 years ago.

      TBH, I had used Emacs before VSCode and had accumulated a bunch of cruft in my .emacs configuration, and I never felt it was "mine" anyway...

    • mickeyp 3 hours ago
      I recommend the tutorial (Help -> Tutorial) from the menu bar inside Emacs to get you started. Don't listen to people telling you to disable this or that. Use your mouse and arrow keys to get started. Don't worry about what other people are doing with their Emacs too much. Pick one thing you want to do with Emacs and focus purely on that (writing Go, taking notes in Org, etc.) and avoid a wholesale move unless you have infinite time and patience.

      See also my reading guide: https://www.masteringemacs.org/reading-guide

      My book is of course an option also, but it costs money.

    • roundcan7998 1 hour ago
      Mastering Emacs: worth every cent. (ignore what author says about it costing money) It is what got Emacs to “stick” for me.

      Just get it already

  • wmedrano 13 hours ago
    I'm excited for the user-lisp/ changes. It'll let me create custom lightweight packages and have them lazily loaded by just sprinkling ;;;###autoload over interactive commands and modes.
  • CodeCompost 4 hours ago
    The section under "User Lisp Directory" seems incomplete. I was expecting a second paragraph.
    • brabel 3 hours ago
      I thought the same, but later on in the article they go into more details and explain that lisp files under that directory will be auto loaded and commands they add should just work! Really good stuff.
  • pkal 16 hours ago
    I was annoyed by some of the comments in the "Packages" section, because it is clear that the author didn't try anything out but just scattered a few comments though out the file.

    Regarding :vc and :load-path, this was obsoleted transitively due to the obsoleting of package-vc-install-from-checkout, which has portability issues. Bug#80604 goes into the background for this. This is NOT an obsoletion of the :vc keyword for use-package.

    Regarding package-autosuggest, this is disabled because it doesn't interest most users. It is targeted at new users who aren't familiar with the packages, and might be interested in new major modes. Experienced users are generally either familiar with the packages and use them or prefer to stay in fundamental mode. The minor mode is enabled as part of the newcomers theme!

    No mention of package-review-policy, which especially in the "age of AI" is an important feature is you want to be careful about external code you are using on your system.

    Oh and on the topic of the newercomers theme, the reason it is not mentioned "higher up" in the NEWS file, besides it being the wrong section, is that it is highlighted on the splash screen, where new users are going to find it, instead of a NEWS file.

    • brabel 3 hours ago
      The post mentioned so many things and went into lots of interesting discussions about the new stuff . I find it amusing you think it’s ok to criticize the author for not trying things out and not mentioning your favorite topics. Here’s an idea: write a better post yourself.
    • mickeyp 3 hours ago
      But I do test things out, by virtue of often running the tip of master branch and submitting bug reports. But I cannot test every mention in the NEWS, so on that part you are right.

      Deprecating :vc + :load-path without expressing why is a curious oversight. And "portability issues" is all fine and good, but why embed custom git clone + build grammar code in the treesit.el file if VC checkout portability is a concern? Surely VC is better at it than a bunch of brittle string concat code in treesit.el I do not understand why one part works and another supposedly does not.

      The change is especially infuriating as for most of us it actually worked fine, and user-lisp directory does not solve the retrieval and setup problem, which `use-package` for all its flaws at least standardises.

      Most users probably do care about discoverability of related packages, existing user or not. But that's in the eye of the beholder.

      `package-review-policy` is security kabuki theatre. Someone who wants to harm an Emacs user can find many other ways of doing so with or without this flag.

  • Quitschquat 5 hours ago
    Anyone know if Zaretskii resigned over the portable dumper?
  • hirvi74 5 hours ago
    I hope my Treesitter issue has been fixed with macOS. I gave up on the problem about this time last year.

    By installing the grammars on the user's behalf, I think I might be in luck!

    I don't remember the exact issue, but I remember having to dig through the release histories of each of the poorly documented ABI version for each language to find whichever versions was compatible.

    I've got my fingers crossed.

    • yanhangyhy 26 minutes ago
      i just gived it a try. works like a charm, treesitter + lsp. i asked cursor to help me with the config.
    • fergie 2 hours ago
      Have also struggled with this- would be great to see a fix
    • mickeyp 3 hours ago
      My Combobulate page has suggested package versions but note I have not yet confirmed 100% compatibility with every single Emacs 31.1 major mode yet, though all tests for Combobulate do pass in 31

      github.com/mickeynp/combobulate