7 ms·
I think Emacs is built upon a golden idea: The programmable text buffer as the user interface for the OS. A lot of data manipulation can be expressed as text m
by continuational 4y ago
I think Emacs is built upon a golden idea: The programmable text buffer as the user interface for the OS.
A lot of data manipulation can be expressed as text manipulation, especially if it only has to be correct in a single instance.
However, Emacs is really starting to show its age. The keybindings are arcane and pre-standardization.
There is no built-in support for multi-cursors, which are often much more direct than macro recording.
Configurations are time consuming and perpetually broken.
I think it's time for a replacement.
- planede 4y agoAm I the only one who doesn't get the multi-cursor hype? Having said that I never used it, so maybe I'm missing out.
- kreetx 4y agoYou are not. Perhaps people who use it can elaborate, but it seems to be an interactive search-and-replace with highlighting. Is it anything more?
- CraigJPerry 4y agoIn vscode if my cursor is in a word, i Ctrl+D to select that, then Ctrl+D to select further matches, then begin typing over them. There's other modes too where you can just add more cursors to a line below/above but i find less use for that. But in vim it's not much slower to do: /<search term> cgn " change this this i just matched . " find next occurance AND execute the change here too, i don't have to say "n ." because i used cgn above instead of something like cw But i still end up relying on qq " stick a macro in q register <complex edit sequence> @q / @@ For more gnarly stuff
- ckolkey 4y agopresuming you did a `/<search>` for the results you want, you can follow it up with: :%s//<replacement>/gc
- deleted 4y ago[deleted]
- alex_smart 4y agoIt is more like interactive editor macros where you can see the intermediate results on the fly. The advantage over search-and-replace is that you get to work with a nice, familiar language (the interactive commands you send to your editor) rather than using regex.
- atsider 4y agoYep, to me it's not far superior to find-replace: https://nullprogram.com/blog/2017/09/07/ https://nullprogram.com/blog/2017/09/07/
- alpaca128 4y agoWith the right controls it might be a better (more flexible) version of Vim's block selection mode. Which I use almost daily, it's super useful but depends on lines being vertically aligned, which multiple cursors don't need to care about. But I don't see another purpose for them; find-replace with regex support and macros only fail in rare cases where actual syntax parsing is needed.
- draxil 4y agoI used to think "surely this is just fancy find and replace". But actually it's more like defining a keyboard macro. It's very powerful and quicker and easier than a macro for a lot of tasks.
- mtnygard 4y agoI think the utility is proportional to the degree of repetition in your files.
- JonChesterfield 4y agoEmacs is essentially perfect. The core of sketchy C is a bit of a liability but mostly works fine. The layers of lisp on top have been evolving for decades. I don't know what standardisation you're referring to, but feel free to change the key bindings to whatever standard you prefer. Built-in? There will be multicursor things on melpa, install whatever sounds plausible. The distinction between ships with emacs and added post-install is minimal.
- vector_spaces 4y agoI find emacs to be very transparent compared to other editors. Also, it's exactly as complicated as I want/need it to be. I love the buffer abstraction, it fits very nicely with how I think in general. And I love that it generally "just works" with my pretty bare bones config. I don't try to do everything inside emacs, probably to a fault. I don't even bother with, say, autocomplete, or on-the-fly syntax checking (I do use syntax highlighting!), I just run linters/formatters/unit tests externally regularly while working on code. I'm happy to defer terminal interaction to a real terminal emulator, although sometimes I use vterm from emacs. Oh, I will use magit though. Magit is awesome! Don't get me wrong, I like VSCode in some ways, and I think it's a great tool. It's far more accessible in a lot of ways. But it's not really for me. I don't find it to be transparent. Things break often, probably because it's a less mature tool, but understanding why things break when they do tends to be frustrating and fraught by comparison. And it lacks anything remotely comparable to emacs buffers (at least last I checked: if you know of anything that does this in VSCode, I'd be happy to check it out!). And to be clear, I know these arguments for emacs aren't super compelling. They're more expressions of taste and aesthetic preferences than anything else. Which is fine, we can all have different tastes and aesthetic preferences :)
- continuational 4y agoI don't really understand how to use VSCode efficiently. IntelliJ IDEA has the best editor I've tried so far. I'm not suggesting it could be a replacement for Emacs, however.
- vector_spaces 4y agoI'm OK with giving up emacs for a powerful IDE in the right setting. I've used Visual Studio with ReSharper while editing C#, and that is a pretty phenomenal experience. But for whatever reason I don't feel like I need it when working on Python, bash, Golang, SQL, JS/TS, or any of the other languages I tend to work with
- medo-bear 4y ago> Emacs is really starting to show its age. I disagree. I came to Emacs from a combination of VSCode/Pycharms and Jupyter notebook. I think the latter are still held in highest regard in the IDE space. To this day there is nothing in another editor or IDE that I miss. I find that Emacs allows me to invest as much as I want into my tools: editor, notebook, document generator, and shell. If you are looking for a maximal out-of-the-box product, then sure Emacs will come up short. However if you are looking for a product that you can develop and use for a lifetime then personally I don't think any one piece of software comes close NOTE: Emacs ecosystem has had support for multiple cursors for over a decade. Emacs (like Python) should not be valued in terms of built-in features, but in terms of its community and ecosystem
- gpderetta 4y agowhat's wrong with the multiple-cursors package? I have been using it successfully for many years. I suspect that emacs will outlast any replacements like it has done for the last few decades.
- alex_smart 4y agoSomeone posted a link in the comments pointing out that Emacs's internal representation of a buffer is not really designed to support multiple cursors efficiently. For batch changes in a large file, macros would be more suitable. I haven't really seen this be a problem in my workflow.
- trey-jones 4y agoI use multiple-cursors and don't have a problem with it. Who cares whether it's efficient? I will prefer lsp-rename where possible, but if I'm replacing some strings or whatever it's very quick to just select the string, and then add a few cursors and change them all at once (I use s-d for that). It's not like I'm using thousands of cursors at once.
- BeetleB 4y ago> However, Emacs is really starting to show its age. The keybindings are arcane and pre-standardization. There is no built-in support for multi-cursors, which are often much more direct than macro recording. Why is it that I always see these complaints about Emacs and not vim? It's as true for the latter.