Live data from Hacker News

Joining the Church of Emacs

fuzzypixelz.com

11–20 of 67 posts

Re: Joining the Church of Emacs

#11
Just wondering is there a way to record macros (similar to vim) and replay them really quickly. I often use this to do batch processing for files, and evil is really slow due to slow rendering after each macro operation.

Re: Joining the Church of Emacs

#12

Just wondering is there a way to record macros (similar to vim) and replay them really quickly. I often use this to do batch processing for files, and evil is really slow due to slow rendering after each macro operation.

https://www.gnu.org/software/emacs/manual/html_node/emacs/Ke... ?

Re: Joining the Church of Emacs

#13

Just wondering is there a way to record macros (similar to vim) and replay them really quickly. I often use this to do batch processing for files, and evil is really slow due to slow rendering after each macro operation.

Yes you can do that in Emacs of course. Default key bindings are "C-x (" to start recording, "C-x )" to stop, and "C-x e" to play the macro — and then you can just press "e" to repeat it again and again.

This is one of the feature that I miss the most when I'm using another editor. So much that I spent some time this summer implementing keyboard macros in Kate, which is also a very nice text editor :). See https://news.ycombinator.com/item?id=32585221

Re: Joining the Church of Emacs

#14
post #13

Just wondering is there a way to record macros (similar to vim) and replay them really quickly. I often use this to do batch processing for files, and evil is really slow due to slow rendering after each macro operation.

Yes you can do that in Emacs of course. Default key bindings are "C-x (" to start recording, "C-x )" to stop, and "C-x e" to play the macro — and then you can just press "e" to repeat it again and again. This is one of the feature that I miss the most when I'm using another editor. So much that I spent some time this summer implementing keyboard macros in Kate, which is also a very nice text editor :). See https://ne…

Alternative default bindings are "F3" to start recording and "F4" to stop recording or replay a macro.

Re: Joining the Church of Emacs

#15
post #13

Just wondering is there a way to record macros (similar to vim) and replay them really quickly. I often use this to do batch processing for files, and evil is really slow due to slow rendering after each macro operation.

Yes you can do that in Emacs of course. Default key bindings are "C-x (" to start recording, "C-x )" to stop, and "C-x e" to play the macro — and then you can just press "e" to repeat it again and again. This is one of the feature that I miss the most when I'm using another editor. So much that I spent some time this summer implementing keyboard macros in Kate, which is also a very nice text editor :). See https://ne…

Since parent is using evil, they can just use q as in Vim (evil-record-macro) in place of kmacro. But the "rendering issues" would presumably apply either way.

Re: Joining the Church of Emacs

#16
Really glad to see more people switching to meow[0]. It felt extremely right after using and being frustrated by both standard emacs and evil.

I wrote the article [1] linked in the post, so that was really fun to see as well!

Tldr: simplicity, extensibility, kakoune grammar, less modifier usage, dvorak/keyboard compatibility, great multiedit system that obsoletes macros in daily usage

(Disclaimer, i work on meow)

[0] https://github.com/meow-edit/meow

[1] https://esrh.me/posts/2021-12-18-switching-to-meow.html

Re: Joining the Church of Emacs

#18
post #4

His alignment formatting example is harder for me to read than what he started with. I have an eye tracking issue so I'm not always the best person to judge this. Is it harder for everyone else?

Just to confirm that there are people who agree with the author: this tidbit actually kept me reading the article! It was the new eMacs thing I learned today. I thought it was much easier to read after aligning. As long as things stay within a reasonable width, that brand of consistency (read “columns”) makes it easier for me to read.

Re: Joining the Church of Emacs

#19
post #13

Just wondering is there a way to record macros (similar to vim) and replay them really quickly. I often use this to do batch processing for files, and evil is really slow due to slow rendering after each macro operation.

Yes you can do that in Emacs of course. Default key bindings are "C-x (" to start recording, "C-x )" to stop, and "C-x e" to play the macro — and then you can just press "e" to repeat it again and again. This is one of the feature that I miss the most when I'm using another editor. So much that I spent some time this summer implementing keyboard macros in Kate, which is also a very nice text editor :). See https://ne…

> and then you can just press "e" to repeat it again and again.

You can also pass C-x e a 0-prefix argument (M-0 C-x e) and it will repeat the macro until the bell rings, which usually happens when a movement command like forward-line, forward-sexp, etc. reaches the end of a buffer.

Another strategy is to record a macro that only operates on a single line, then mark the region you want to repeat it in for every line and then execute it on all these lines using C-x C-k r.

Re: Joining the Church of Emacs

#20
post #9
post #5

Earlier quoted context omitted.

In IDEs that support refactor-renaming (Emacs probably does?), the column-aligned formatting also has the drawback that it breaks (unless the refactoring also auto-realigns all affected code). For example, one = 1 fortyTwo = 42 elite = 1337 might become: one = 1 ultimateAnswer = 42 leet = 1337 This made me stop column-aligning in most cases. An exception is array initializers for two-dimensional tables with many colu…

It also makes git blame a lot less useful in these scenarios.

You can pass git blame -w to ignore whitespace changes, though yes, in general it is annoying.
Post reply on HN