21 ms·
The Anvil Text Editor
- kookamamie 2y ago[flagged]
- globular-toast 2y agoI read it more as a comment on the library itself, not the UIs that you can create with it. But, in any case, I find this beautiful because not a single line is wasted on anything that isn't text, yet I can easily see what is what without it hurting my eyes.
- deleted 2y ago[deleted]
- 2143 2y agoIsn't that what's meant by "functional"?
- deleted 2y ago[deleted]
- euroderf 2y agoIf this can be compiled into WASM and embedded in a web page...
- andrewshadura 2y agoI’m not convinced Snarf is still a good name for any function in any piece of software these days. Or ever was, to be honest.
- major505 2y agoSnarf always remembers me of the Thundercats pet.
- tempfile 2y agoIt got that name from Acme. I don't think it's any worse than "yank", which most of us continue to put up with.
- lynx23 2y agoOne (kill) ring to find them...
- andrewshadura 2y agoI know it has. That's why I said "still". To be honest, yank is also not great. Both terms were invented back in the day the industry hasn't settled yet on copy and paste. For new software, choosing such names is counter-productive.
- deleted 2y ago[deleted]
- nanna 2y agoYeah definitely should be something modern and respectable like Hugging Face
- aquariusDue 2y agoAnvil piqued my interest especially because it provides a REST API to interact with it opening the door to writing extensions in practically anything, similar to Kakoune in that regard. But what I find odd is that there's no mention of a repo (though it has a link to a Discord server) anywhere on the site as far as I've seen. Sadly there's no mention of LSP either which is kinda a deal-breaker these days nor anything about tree-sitter. But at the same time this might mean that Anvil is free to experiment with its own solutions without being tied to a standard. Every cloud a silver lining or how it goes. Gio also seems like a solid choice for the UI. I hope Anvil becomes more popular, it would be fun to see a new generation of niche text editors duke it out between Lem, Helix and Anvil.
- Arch-TK 2y ago> multiple cursors But seriously though, why does everything these days need multiple cursors? It's a confusing visual gimmick in every scenario I've seen it implemented in. I'll take fully fleshed out structural regular expressions or even perl-re over multiple cursors any day. Combined with as vim's [c]onfirm flag you get all the benefits of multiple cursors without all the clunky downsides and weirdness.
- wodenokoto 2y agoWhen I need to edit the code around next five instance of "foo", but not every instance in the open file, then I don't know how to do that with structural regular expression, but pressing ctr+d five times and then edit what I want is really straight forward. And I need to edit around a limited version of foo way more often than I need to edit all instances.
- globular-toast 2y agoYou would restrict your regexp to a region. In Emacs you just select a region somehow (like your press ctrl+d five times), then just do the regexp replace.
- vulcan01 2y agoNotice that you also don't need to write a regex with multiple cursors - instead, you can visually see your selections and changes as you go, using the same editing motions that you would typically use.
- msravi 2y agoIn vim, to replace in the next 5 lines (not instances) :.,.+5s/findtext/replacetext/g In neovim, you'll see a preview of the changes as you type the regexp. Neovim is really good.
- buster 2y agoIt's mostly a matter of taste. I do use multiple cursors quite often in Sublime Text when needing to edit some CSV or JSON file. It's probably the feature of Sublime Text, why i'm still having the editor around. It work's extremely well. I could type ":.,.+5s/findtext/replacetext/g" in vim (and remember the syntax!) or i just could do "ctrl-d, ctrl-d, ctrl-d, ctrl-d, ctrl-d, replacetext" and have a visual, immediate confirmation on what i am doing. But i bet you, that i'll press ctrl-d 5 times faster than you entering ":.,.+5s/".
- mkovach 2y agoInteresting. I don't know if it will distract me from Acme, but I will try. I'm unsure if I am ready for a rest API interface when the 9p interface to Acme works so well.
- xpe 2y agoFor those who have used Anvil, what are the key differentiators for you?
- msravi 2y agoYou don't need more than one cursor in vim: https://medium.com/@schtoeffel/you-don-t-need-more-than-one-cursor-in-vim-2c44117d51db https://medium.com/@schtoeffel/you-don-t-need-more-than-one-... But if you really want it: https://github.com/mg979/vim-visual-multi https://github.com/mg979/vim-visual-multi
- archargelod 2y agoThere's also vis[0] It is an editor that combines best parts from vim and plan9 sam[1] (multiple cursors, structural regular expressions). 0 - https://github.com/martanne/vis https://github.com/martanne/vis 1 - https://en.wikipedia.org/wiki/Sam_(text_editor) https://en.wikipedia.org/wiki/Sam_(text_editor)
- disintegrator 2y agoI really love working in neovim but this is a frustrating position that much of the community has taken. Editing multiple sites _simultaneously_ is nowhere as intuitive as with VS Code and IntelliJ/Sublime before it. - Repeat - `.` - is ok for some bulk manipulations but in my opinion it's not as nice because it's after the fact. I like that in VSC I select all the occurrences I want to edit first and then if the selections match my expectations I go ahead. - Visual mode only lets you work vertically in a contiguous block of text. That's not the same or as convenient as multi-cursor in VSCode where I can select the word "const" for example and ⌘-D to select more occurrences of it anywhere in the buffer, not just above/below, and bulk edit them to "let". - Macros are often what I lean and they can do far more than multi-cursor editing could but they are far more tedious to string along and repeat when all I want is to change some text in multiple locations. - Text replacement (sed) is also fine but not as convenient in my opinion. Either way, neovim will be getting native multi-cursor support and I'm very excited about that because I'm not particularly fond of VS Code (in terms of perf/resource usage) but I recognise (neo)vim doesn't have a monopoly on good ideas.
- stronglikedan 2y agoI may not need it, but every operation they demonstrated is significantly slower than using multiple cursors, so I definitely want it.
- deagle50 2y agoThe window management looks great but going back to mouse-driven input is a non starter for me. Anvil with vim motions would be interesting.
- submeta 2y agoWe have Emacs/vim at one end of the spectrum and VS Code at the other. What else do we need? At this point I feel like these poor souls waste a lot of their energy to develop something that has perfect solutions already out there. Or you need to come up with something that totally transcends the way we write (ascii) text.
- OmarAssadi 2y agoI did already write my own comment trying to ask about the goals and state of Anvil when compared to Acme. That said, RE: "Emacs/Vim on one end and VS Code on the other" and "... you need to come up with something totally transcends the way we write" -- the latter is actually the reason why I was genuinely curious. I haven't had the time to give Acme a proper try myself, so who knows whether I'd hate it or love it or what, but it only took a few minutes of Russ Cox's little introduction video [1] on Acme for me to go, "Whoa, that is unique"; half the concepts gave me a near-instant visceral feeling of simultaneously being disturbed yet also somehow delighted. I am really unhappy with the direction of modern UI design, and much of software in general, but sometimes I wonder how much of my feelings are truly objective, how much is my own bias, and how I would feel if I grew up in a totally different environment with different stuff. I've kind of always been curious in that sense, if you took a group of people who somehow had been totally isolated from not only computers and software, but our various cultural biases, what would they find to be the most intuitive, and what sort of things would they come up with? In a similar sense, for better or for worse, that is almost how I felt seeing Russ use Acme; it looked like an editor built by aliens for other gremlin-like aliens. I can't confirm or deny whether the aliens are right about their editing paradigm, but it is at least something much closer to "transcending the way we write (ascii) text" than most, and so it's cool to see Anvil is at least drawing inspiration from that rather than, say, yet another VS Code. [1]: https://www.youtube.com/watch?v=dP1xVpMPn8M https://www.youtube.com/watch?v=dP1xVpMPn8M
- reportgunner 2y agoMaybe one of these will grow into emacs+vim+vs code and make them obsolete ? We didn't just spawn in with computers having vs code emacs or vim already installed you know.
- hdb2 2y agoI know this is a minor gripe, but something isn't right with the https version of this site.
- jimbob45 2y agoYeah, the site flagged as malware for me.
- lexoj 2y agoI opened my project with Anvil on a mac (without mouse) and I cant figure out how to open a local file. Skimming through docs and I didnt find it. A video would have been very useful here.
- OmarAssadi 2y agoWhile looking into Acme several months back, I actually bumped into this; there just don't seem to be many editors that draw inspiration from Acme's workflow rather than borrowing from things like Vim, Emacs, or more traditional mouse-based GUI editors -- e.g., Notepad++, Sublime, Kate, VS Code, etc -- so Anvil popped up pretty much instantly while searching around for similar concepts. However, as someone who hadn't, and unfortunately, still hasn't, spent a load of time using Acme, it wasn't super clear to me how they differentiate from each other. I wasn't totally sure whether it was more of a clone made for fun of it, or whether Anvil was trying to solve a genuine issue that Acme wasn't, or was trying to solve in its own distinct way, or perhaps trying to address a gripe with Acme itself, etc. If anyone working on the project could highlight some of the differences in features and goals, or if anyone who has used one or the other long enough to notice some stuff at a glance, it'd be super helpful as an outsider to both. Superficially, I do see syntax highlighting, but I figure there's probably more going on than that. Also, is there any sort of publicly accessible version control? I see the source archives, but I couldn't find any sort of mention of git or any other vcs. FWIW, by the way, I hope asking about a comparison doesn't come across as some sort of dismissive, "what's the point", comment; it was just cool and interesting enough that this isn't the first time I've wanted to ask.
- hollerith 2y ago>whether Anvil was trying to solve a genuine issue that Acme wasn't The last time I checked Acme used its own text-rendering algorithms and its own fonts (this is the Acme that is part of plan9port) which wouldn't be a problem except that the visual details (I am pretty sure Acme was using bitmapped fonts) clashed pretty strongly with the rest of the system (I was using a Mac at the time). The browsers do their own text rendering, too, but the rendering is tuned to match the OS the browser is running on. Point is, although I could've gotten used to the tiny details of how Acme renders text, I despaired of ever getting used to frequently switching my gaze back and forth between Acme's window and the other windows on the Mac. In contrast, the text in the Anvil window does not clash with all the other windows on my system (which is no longer a Mac, but rather Gnome / Linux). So that is why I rejected Acme quickly after installing it, but am still interested in Anvil (the existence of which I learned about about an hour ago).
- imiric 2y agoThis is very interesting, and it's great to see new editors. But honestly I never got the fascination for the Acme editor. It seems powerful, but relying on mouse input is limiting, slow and imprecise. I'd much rather control my editor using the infinite key combinations of the keyboard I'm already typing on, which is much more comfortable, accurate and faster. It also builds muscle memory that can never be built with an analog input method like the mouse. Multi-pane editing is also not very useful beyond a single vertical or horizontal split. For anything more complex, a tiling window manager is a more versatile tool that works for any app. To enable these two functionalities UI elements need to be rendered, which clutters up the UI and takes up considerable screen real-estate. When working in a buffer and keyboard-oriented editor like Vim or Emacs, the screen only needs to show the content itself, which is a much more pleasant environment to work in. But maybe I'm misunderstanding the benefits of the Acme workflow, and I honestly haven't given it a thorough try, so I'd be happy to read counterpoints. BTW, I love the font Anvil uses! Is it available somewhere to download?
- jxy 2y agomouse or keyboard is really just a preference. you could do mouse 1 sweep-select 2-3 in one window, and move to another mouse 1-3, and move to another do mouse 1-3, ... Or you could do, in case of vi, y$ (or other movements), ^w w (or other way to select other window), (move your cursor) p, ^w w, (move your cursor) p, ... Though I'm biased, because I feel it's much easier to move my mouse than do one of wWbBeE^$fFtThjkl to move my cursor, even though it is a lot faster and efficient to only move a few of my fingers than my whole arm. the font is likely Go Font, the proportional one
- imiric 2y agoAha, right, cursor movement across large distances is indeed more comfortable with the mouse. This is usually awkward with the keyboard, and requires plugins like EasyMotion, or just holding keys or repeating key combos. I think these movements are rarer than small cursor movements, like jumping to the next character, word, line, etc., or jumping to the matching brace, etc. In these cases using the keyboard is still faster and more precise. But I was more thinking about controlling the editor itself. Creating new buffers/panes and switching between them is all much faster with a keyboard. For example, I bind `=` and `-` to switch to the previous/next buffer, and Tab to switch to the next pane. I do these actions hundreds of times a day, and they're just a keystroke away. I couldn't imagine having to use the mouse for this. It would be unbearably slow and tedious. The best part of key bindings is that they can be easily modified to suit any workflow. Whereas with mouse movements you really can't customize them beyond which of the few buttons to click. The movements themselves can't be optimized, unless you go into gesture territory, which has a lot of drawbacks as well. No, it doesn't look like the Go font, but thanks.
- haolez 2y agoHow's the feature parity with Acme + plumber + other Plan9 stuff? This feels like a modernization of Acme and it sounds like a very good idea to me. If it's not immediately a better alternative to VSCode and other IDEs, it can be seen as a platform for integrating external tools and have a cohesive experience (similar to what Emacs offers). I dig it!
- Dubhead 2y agoad is another text editor inspired by Acme: https://github.com/sminez/ad https://github.com/sminez/ad
- bwidlar 2y agohttps://www.youtube.com/watch?v=jb2pAi5hLUg https://www.youtube.com/watch?v=jb2pAi5hLUg
- createaccount99 2y agoIt seems good but as others have mentioned, LSP/tree sitter pretty much must-have these days. And I'd like to see inspiration taken from OniVim's "sneak" feature, which is basically link hints (or ace jump) for all the buttons in the UI, which makes mouse actions doable with just the keyboard, in an intuitive way.
- anta40 2y agoI'm on M2 Mac (Sonoma 14.5). How to run this? ./anvil [1] 25270 killed ./anvil chmod +x, xattr -dr com.apple.quarantine etc don't work.