Live data from Hacker News

VS Code can do that?

vscodecandothat.com

211–220 of 280 posts

Re: VS Code can do that?

#211

Earlier quoted context omitted.

I started playing with emacs 24 years ago, then spent 20 years as a devoted vim user with a two year work-enforced gap in Eclipse. I tried spacemacs in evil mode about four years back and stayed for magit. I tried VSCode a few weeks ago to see what the fuss was about and had my Eclipse PTSD triggered. Magit, mu4e, elfeed, eww, multiterm, restclient.el, tramp, [edit]org-mode![/edit], the list of replacements for bloat…

I am using vim for years now, and I haven't written more than 50 lines of vimscript apart from the bundles. Most of the thing that I have written is just maps, some configuration for other bundles, and some copied better defaults. I still don't get it when people say they heavily use elisp. Can anyone give example of a highly custom thing that you do in emacs/vim/any other editor, for which there is no famous bundle…

I occasionally use elisp while replacing with regex(you can do computation on captured strings), can you do this in vim?

Re: VS Code can do that?

#212

Earlier quoted context omitted.

I don't know how people program without this feature You must do some kind of programming I've not encountered in my many years. While my editor of choice can do this, I would have no idea how, because a feature like "increment duplicates" is needed so infrequently that I would never remember the shortcut.

Increment duplicates is just one of many, many utilities that pairs well with multiple carets. Formatting is another. Boilerplate code, for example today I had to implemented code like this: impl Into for ProcessNode { fn into(self) -> Node { Node {some_boilerplate(self)} } } I had 6 node types. Using multiple cursors I: * Implemented it once * Duplicated it 5x * Copied the names of the types I needed to impl for * A…

Or you could write a macro?

Re: VS Code can do that?

#213

Earlier quoted context omitted.

Because he needs it wrapped in a promise, sending a resolve/reject?

Fetch and response.json() both return promises. So it's still a promise.

True and in this particular example for response.json() it doesn't even matter.

Re: VS Code can do that?

#215
post #211

Earlier quoted context omitted.

I am using vim for years now, and I haven't written more than 50 lines of vimscript apart from the bundles. Most of the thing that I have written is just maps, some configuration for other bundles, and some copied better defaults. I still don't get it when people say they heavily use elisp. Can anyone give example of a highly custom thing that you do in emacs/vim/any other editor, for which there is no famous bundle…

I occasionally use elisp while replacing with regex(you can do computation on captured strings), can you do this in vim?

Yes, select in visual mode type :! and it gets processed by a unix command.

Re: VS Code can do that?

#216

Earlier quoted context omitted.

sure, but would we even be here talking about VS Code if it had been written in those languages? Would the extension community have grown as quickly? Would Microsoft have continued investment in the product if it hadn't? I'm not saying that it wouldn't have been as successful, but we're here, now, and it is. It's a great product regardless of the fact that it's written with HTML/CSS/JS.

I like VS Code and Atom, so please understand my criticism here doesn't come out of hate or disdain. Vim has a pretty huge community of plugins, and with NeoVim that plugin development has greatly accelerated. Intero, Fireplace, Vim FSharp (which works on regular Vim as well), and NeoComplete are excellent, and make NeoVim competitive with a lot of IDEs in my mind. Part of the reason I don't use VS Code is that I rea…

It's just a guess, but I think the main reason to run VSC in a browser is that they can later also let in run in a browser, without install. You will develop, store, and run your code on Azure, without any local installation.

(I don't know if that is a great vision, but it is a good rationale to use Web tech for IDE development)

Re: VS Code can do that?

#217
post #115

Earlier quoted context omitted.

I keep hearing good things about VSCode. If I weren't essentially married to emacs I'd definitely try it out. I'm not sure I'd recommend emacs to everyone at this point, though I think it remains a really solid choice of editor/OS for people willing to get over the learning curve and put up with a bit of clunkiness. Re the git stuff though- one place that I'm pretty sure emacs is the uncontested champ is in git integ…

I wholeheartedly agree: Magit is that good, really. The way I see it, it reduces the burden associated with carrying the required git mental model in your mind, by giving you easier points of entry into its complexity. I owe all the slightly more advanced things I now routinely do with git (which would probably be seen as pretty basic by a lot of people though) to Magit, without question.

Yep- I was reminded of how much I like magit by this thread so I just made a $100.00 donation to its development. I hope it inspires other people to at least give magit a try (if I'll donate that much it must be good, right?)

Re: VS Code can do that?

#218
post #117
post #105

I recently switched to JetBrains products. Their IDEs are much smarter. Infinitely better than VS Code, Sublime and whatnot. It's the closest thing to pair coding!

VS Code can do that too: https://code.visualstudio.com/visual-studio-live-share

I meant the IDE acts as another pair of eyes on your code.

Re: VS Code can do that?

#219

My favorite is multi-selection mode. It's not the same as "Column Mode" you find in other IDEs but try it and you will never want another editor again: (Option)Alt-Cmd + Down or Up arrow key From there, you can use arrow keys as normal, but instead of controlling one carrot, you control all the ones you created. So if I use the shortcut key to move to the next word, they all do, same with end of line, or what have yo…

This exists in most editors I've used (intellij is alt + shift + click or double tap alt, if I recall). I don't know how people program without this feature - they should teach this shit in school. Multicursor is amazing. One thing it's been great for: I have code like: byte b1 = array[0]; And I want to do this for 16 bytes. Control + D to duplicate 15x. Double tap control, hit up 15 times - now there's a cursor at e…

Where did you find "duplicate and increment"?

Re: VS Code can do that?

#220

Earlier quoted context omitted.

I started playing with emacs 24 years ago, then spent 20 years as a devoted vim user with a two year work-enforced gap in Eclipse. I tried spacemacs in evil mode about four years back and stayed for magit. I tried VSCode a few weeks ago to see what the fuss was about and had my Eclipse PTSD triggered. Magit, mu4e, elfeed, eww, multiterm, restclient.el, tramp, [edit]org-mode![/edit], the list of replacements for bloat…

I am using vim for years now, and I haven't written more than 50 lines of vimscript apart from the bundles. Most of the thing that I have written is just maps, some configuration for other bundles, and some copied better defaults. I still don't get it when people say they heavily use elisp. Can anyone give example of a highly custom thing that you do in emacs/vim/any other editor, for which there is no famous bundle…

The question is not elisp v. vimscript but rather the power of not having to switch contexts. To write code for a locally-hosted RESTful API I used Chrome to read the API docs, Postman to make the calls, iTerm2 to start/restart the server and read the logs, and a text editor to make changes. I replaced that flow with eww, restclient.el (amazing!), multiterm, and an editor buffer. No changing of context, conserve about ~1GB RAM in Chrome instances, full-screen if I want it, and everything is text (I'm looking at you, Postman).

On the "highly custom" level, I have a work-in-progress script that takes a URL, sends it to a Splash server, and returns the rendered HTML to eww for viewing. This is great for annoying SPAs like the article that spawned this conversation.

My current goal is to swap out my development MBP with an eInk tablet and bluetooth keyboard. Success will be measured as a function of productivity and weather-/water-/environment-proofing of the device; the goal is productivity in full sunlight and/or under water. Emacs will have a central role in that. Just need to find an eInk device with adequate screen refresh rate and Bluetooth support....

Post reply on HN