News for hackers. Stuff that matters.
Re:Mastering Emacs: What's new in Emacs 29.1 by ashton314 on Thursday September 07, 2023 @08:42PM (#37427769)
This little project of mine made the front page here a few days ago, so I’m not trying to beat a dead horse or anything, but I just want to surface it here again in case anybody finds it useful.

I have made a starter kit at leverages many of the now built-in features of Emacs 29.1. You can get very far with regards to completion, project management, language, server, etc. just by tweaking a few defaults. I have put some of these nice tweaks together in a starter kit called “Emacs bedrock“: https://sr.ht/~ashton314/emacs-bedrock/

Let me know if you find it useful, or if you have any comments or suggestions. :-) I’m still working on incorporating some feedback I got earlier.

Re:Mastering Emacs: What's new in Emacs 29.1 by bradrn on Thursday September 07, 2023 @09:37PM (#37428208)
I’ve used Emacs for quite a few years now, but I had a look at emacs-bedrock when it was posted, and discovered a whole bunch of interesting settings and packages I’d never seen before. I’ve now switched my config over from Ivy to Vertico (and associated packages), and am much happier with it. Thank you so much for making this!
Re:Mastering Emacs: What's new in Emacs 29.1 by ashton314 on Thursday September 07, 2023 @11:13PM (#37428781)
Daniel Mendler (minad on GitHub) et al. have some seriously awesome packages. The latest one I’ve fallen in love with that I haven’t yet added to bedrock is Jinx [1]: a fast spell-checker that supports multiple languages in the same buffer, checks spelling of words based off of font-lock class (read: spell checking in doc strings and comments but not in actual code) and a slick interface that makes correcting words a breeze.

I’m so happy to hear you’ve found some helpful things from bedrock! Happy hacking!

Re:Mastering Emacs: What's new in Emacs 29.1 by bradrn on Friday September 08, 2023 @04:31AM (#37431055)
> Daniel Mendler (minad on GitHub) et al. have some seriously awesome packages.

Absolutely! What I like about them is how they each focus on doing one thing well, making use of built-in functionality so they all work well with the rest of Emacs. It makes a nice change from the bigger packages which are so featureful they become hard to understand.

Re:Mastering Emacs: What's new in Emacs 29.1 by mickeyp on Friday September 08, 2023 @04:36AM (#37431088)
`flyspell-prog-mode' can spell check comments and strings just fine, too.
Re:Mastering Emacs: What's new in Emacs 29.1 by JNRowe on Thursday September 07, 2023 @09:30PM (#37428157)
A link to that discussion for those of us who missed it - https://news.ycombinator.com/item?id=37385716
Re:Mastering Emacs: What's new in Emacs 29.1 by jordigh on Thursday September 07, 2023 @09:20PM (#37428090)
Heh, people are still putting up their config files online and blogging about them, eh?

Some things in Emacs never change, no matter how many bells and whistles are in the latest version. :)

Re:Mastering Emacs: What's new in Emacs 29.1 by adityaathalye on Friday September 08, 2023 @12:46AM (#37429441)
Yes, we are :)

I just published my newly hand-rolled config https://github.com/adityaathalye/dotemacs

At some point if/when I upgrade to 29.1, I will be able to delete some lines such as the ones that install use-package. :)

Re:Mastering Emacs: What's new in Emacs 29.1 by Scarbutt on Friday September 08, 2023 @01:05AM (#37429572)
Wait until you learn about users of that editor called vim.
Re:Mastering Emacs: What's new in Emacs 29.1 by tmalsburg2 on Friday September 08, 2023 @04:34AM (#37431077)
It's the whole point of Emacs that it's malleable and can (should) be tailored to the own personal users needs.
Re:Mastering Emacs: What's new in Emacs 29.1 by lenkite on Friday September 08, 2023 @12:31AM (#37429341)
Really tempted to try out emacs 29.1. I wish someone would compare Neovim with all the bling aginst Emacs with all the bling - with all the pros/cons along with startup-times and performance (intellisense, etc). Want to get out of vscode.
Re:Mastering Emacs: What's new in Emacs 29.1 by worthless-trash on Friday September 08, 2023 @01:02AM (#37429547)
The "bling" depends on the use case, emacs has many packages not all of which can be installed and in use at the same time.
Re:Mastering Emacs: What's new in Emacs 29.1 by Shared404 on Friday September 08, 2023 @02:27AM (#37430144)
Haven't done a full writeup, but Doom Emacs is _really_ nice.

Takes a little while to acclimate, but it's very useful once you're used to it.

Re:Mastering Emacs: What's new in Emacs 29.1 by reddit_clone on Friday September 08, 2023 @01:18PM (#37436472)
Ya I am a fan of Doom Emacs too. It is the world of Vim wrapped in world of Emacs. Best of both worlds.
Re:Mastering Emacs: What's new in Emacs 29.1 by witx on Friday September 08, 2023 @05:03AM (#37431256)
I left emacs around 2018 or 2019 after 8 years of use as my main. A couple weeks ago I started configuring neovim to use it as my main editor outside of work. I'm doing mostly what I did back when I started with emacs which was copy and pasting the code that the plugin creaters advised and go from there. My main takeaway is that Lua is an immensely better language than Lisp for this use case, and when something goes wrong I feel the same about the stack trace.

I've had a better experience tweaking the configuration in Lua as well. I never tried neovim's starter frameworks (NVChad, LunarVim, etc) so I can't compare them to emacs's. I was never able to use well emacs's frameworks because either they were too convoluted ann hard to customize or kept crashing.

Also when opening or formatting large files (sometimes not so large) emacs would freeze for a very long time. Also, LSP was not around, or was in its infancy, so my experience with code completion and intellisense was very poor, but perhaps that has changed.

Finally, emacs's plugin called "Magit" is a godsend and I lack a similar tool ever since.

With all that said emacs was very special for me because it fueled my passion for open software and being able to control and customize the tools I use. I really hope it got better and keeps kicking!

Re:Mastering Emacs: What's new in Emacs 29.1 by flutetornado on Friday September 08, 2023 @05:39AM (#37431537)
Try neogit plugin for neovim. Its a work in progress.

https://github.com/NeogitOrg/neogit

Re:Mastering Emacs: What's new in Emacs 29.1 by witx on Friday September 08, 2023 @06:08AM (#37431712)
Good to hear, thank you!
Re:Mastering Emacs: What's new in Emacs 29.1 by karl42 on Friday September 08, 2023 @11:28AM (#37434839)
Did you try fugitive as a Magic replacement?

https://github.com/tpope/vim-fugitive

Re:Mastering Emacs: What's new in Emacs 29.1 by lycopodiopsida on Friday September 08, 2023 @06:00AM (#37431676)
I can share my perspective, as doom emacs user for some years (3, I think) who after some back and forth switched to neovim (I've had some vim experience before). If I had to summarize my emacs experience I would say that I like the idea, but I do not like the implementation. It is undoubtedly a cool project with an enormous scope, but while vim is a sharp tool complementing the terminal and usage of other tools, emacs is a kitchesink, which tries to pull everything in. There is no problem with it per se, but the quality of emacs solutions is often hit & miss. These are very generic (ideological) complains, I can name some concrete issues I've uncounted.

- The ecosystem is sometimes difficult. There is always a lot going on in terms of various completion frameworks and spellchecking. It is cool, but often you choice will have some consequences down the line. You like eglot, as a simple and faster alternative? Fine. But it does not support DAP, now you have to pull heavy LSP, treemacs and other 30 packages.

- Treesitter is a chance missed, they've introduced alternative mods for it, with a separate names, which makes it necessary to rewrite the hooks and generally makes a huge mess for no good reason. I guess, the reasoning was like "we do not want to force an external dependency", but there is simply no good reason to regex parsing if you have treesitter and it will be the standard, I am quite sure. Some kind of config switch for a mode would be a better solution.

- It is notably slower than neovim. I cannot describe it, it is more of a "micro-stutter here, micro-stutter there" feeling. It is more visible if you intend to use it for everything or as an IDE replacement, as an advanced editor emacs has a fine performance.

- The UI is... I don't know, I can never predict where a buffer will appear. Emacs in general will pop up a lot of buffers. Sometimes you can close them with q, sometimes you will have to hide them. "Inconsistent" is the word which comes into my mind.

- Org is outstanding as a technical outliner, so-so as a GTD tool. Sync problems and lack of good mobile clients shows.

- Configuring and introspection are good. I still have no idea how to debug my neovim config, for example, it is a non-issue in elisp, you don't even need to restart it, just eval parts of you elisp code!

- Embark is also a very very cool idea.

- Modern completion frameworks are good, vertico, marginalia, orderless - they are easy to configure and very performant. I just like Telescope in neovim more, since it looks better and shows a bigger code preview.

- Evil is a very good vim-like layer, but also quite heavy and sometimes you will have to deal with emacs keybindings. They are not bad, though, it makes sense to learn at least the basics. Due to evil I will leave the keybindings out in general, you can have it either way in emacs. Evil is the best vim implementation outside of vim/neovim.

I've settled on neovim with fish shell, git in console and occasionally lazygit and it is fine. It is hard to describe, but a focused, fast and composing editor is very pleasant to use. I also find neovim more aesthetically pleasant, although it is really just a personal perspective. But what is certainly is, is being simpler. Maybe it is just a natural consequence of aging, but I recognize a lot of value in simple tools: A lever espresso machine instead of a microcontroller-ridden monstrosity with a tablet attached, go instead of rust, console tooling instead of an IDE. Neovim just fits in.

Re:Mastering Emacs: What's new in Emacs 29.1 by confd on Friday September 08, 2023 @08:20AM (#37432573)
This is the most balanced and relatable criticism of Emacs that I've read. The points about Org is an outliner vs. a task manager, the package ecosystem, the UI stand out and integration with external toolings stand out.
Re:Mastering Emacs: What's new in Emacs 29.1 by dmm on Friday September 08, 2023 @09:03AM (#37432953)
> The UI is... I don't know, I can never predict where a buffer will appear. Emacs in general will pop up a lot of buffers. Sometimes you can close them with q, sometimes you will have to hide them. "Inconsistent" is the word which comes into my mind.

In my workflow I embrace the chaos: commands/mode open windows as needed and I use winner-mode to restore my layout.

For example, if I have two side-by-side code windows open and I open magit with c-x g, it will create a new vertical split. Once I'm done with magit, I can use winner-undo once (or thrice depending on what magit ops I did) and it restores the original layout.

Re:Mastering Emacs: What's new in Emacs 29.1 by alwaysbeconsing on Friday September 08, 2023 @12:10PM (#37435502)
> the reasoning was like "we do not want to force an external dependency"

It was not the optimal solution, agreed. The reason was actually that a significant technical complexity was found while trying to adapt the existing modes. The syntax table vs. tree-sitter parse tree was simply too divergent for a mode to be just switched from one to the other. So the decision which I don't think anybody was completely happy with, but considered the only feasible way to move forward, to have new modes with tree-sitter.

You can see some discussion here: https://old.reddit.com/r/emacs/comments/15g9cna/why_is_emacs... and quick link to the mailing list thread: https://lists.gnu.org/archive/html/emacs-devel/2022-12/msg01...

Re:Mastering Emacs: What's new in Emacs 29.1 by yakubin on Friday September 08, 2023 @01:15PM (#37436433)
> - The UI is... I don't know, I can never predict where a buffer will appear. Emacs in general will pop up a lot of buffers. Sometimes you can close them with q, sometimes you will have to hide them. "Inconsistent" is the word which comes into my mind.

I fixed that by redefining in my config split-window-preferred-function to my own function, which is responsible for the placement of new windows in a way that makes sense to me (which is something that no other piece of software does actually).

Re:Mastering Emacs: What's new in Emacs 29.1 by elevader on Friday September 08, 2023 @02:28AM (#37430156)
Your starter kit inspired me to finally bite the bullet and write my own emacs config from scratch instead of using doom. I'm not sure yet if I'm thankful for that, time will tell ;)
Re:Mastering Emacs: What's new in Emacs 29.1 by globular-toast on Friday September 08, 2023 @03:46AM (#37430731)
I saw this and finally after 15 years of using emacs I will be recommending it to people and getting them to use this starter kit. Previously I just couldn't explain to people what I love about emacs without thinking about the huge barrier they have to overcome to make it nice. I also couldn't in good faith recommend a "batteries included" starter kit like doom because I don't use it and I'm not sure if it has what I love about emacs which is it sets you free.

I've also read the linked blog post about avy and forced myself to get familiar with it. Jumping all over the screen is great (I set it up jump across all visible frames in my tiling wm). I'm going to investigate consult et al next (already use vertico and orderless).

Re:Mastering Emacs: What's new in Emacs 29.1 by Otek on Friday September 08, 2023 @04:32AM (#37431062)
It amazes me that it took so long for emacs to have this kind of started kit. And I haven’t thought of it either. Thank you and please support it!
Re:Mastering Emacs: What's new in Emacs 29.1 by tagfowufe on Friday September 08, 2023 @04:46AM (#37431152)
It's incredibly useful to me. I love it. I find it nicely curated and true to the word 'starter' (kit). If I knew more about Emacs, this is definitely what I would have created, and in a similar manner.

It's that lil' layer of configuration that's missing that makes the first clash with emacs sane. I like the structure. I also like the fact that there's a 'researcher' mixin. Would absolutely love to see your opinionated inclusion of org-roam, and general.el.

I recently dabbled into System Crafters' 'Emacs from Sratch' series [0], which is incredibly well thought-out. After 5 hours of following it, you kinda get feature parity between his config and this; but in Berock's case it's done more natively which is really, really neat. I only miss some basic config with general.el.

I feel super lucky to have started in Emacs when they finally added LSP and Treesitter support, and with System Crafters' help and yours!

[0] https://www.youtube.com/watch?v=74zOY-vgkyw&list=PLEoMzSkcN8...