Earlier quoted context omitted.
In general though Emacs single handedly can do most of everything required in software development. One could practically spend all ones development time inside it, so I would say Emacs workflows are more impressive than Vi ones, especially since so much of great functionality is baked into it without even needing pluggins. This I say after a couple of recent days in which the GUD gdb interface was a great help in so…
All these points are also natively handled by vim. Except for 5 which needs an external cli calculator.
Vim Creep (2011)
111–120 of 169 posts
Re: Vim Creep (2011)
#112Earlier quoted context omitted.
My .bashrc is on a quest to turn my yakuake into the better half of vscode. "The shell is my IDE" is definitely true. Though Google takes up a worryingly large fraction of it. Wonder if there could be a shell tool to just dump the first stackoverflow hit for a search. bashrc highlights: https://gist.github.com/FeepingCreature/649588a2f6fa27c717bd... - ctrl-G for "directory up" - ctrl-E for "find and open in editor" (…
Can you explain the fzf binding? I don’t get what’s going on there
So if you want to edit a file from inside a directory easily, you can do:
vim $(find | fzf)
Re: Vim Creep (2011)
#113I'll stick to an IDE. Modern IDEs are sophiscated enough that a Vim/Emacs newbie user probably needs years of practice and tons of plugins to match and go over its capabilities. I think Vim makes a lot of sense when 1) the machine doesn't have a proper IDE, and 2) you really do a lot of programming every day and you are young, like in 20s, so you can amortize the cost for longer time.
3) You get joy from tweaking and heavily customizing your editing environment (as I do).
Re: Vim Creep (2011)
#114Earlier quoted context omitted.
Not to be too pedantic but shouldn't that be ddGp? Also, have you tried the Vim plugin for VSCode?
I've tried the Vim plugin for VSCode a few times personally, but I don't trust it. It's incomplete, and it has its own secondary understanding of history that can get you into trouble when it interacts poorly with VSCode's own history. Anyway, that was my experience for my short time using it. I'm curious if there are any longtime vim users using VSCode with the Vim plugin, and if so, what are their experiences, and…
There are a few reasons why I use a vim plugin instead of vim proper for most day-day work:
1. I do plenty of data science-y stuff that requires support for good visuals. Vim's support here is pretty lackluster and Jupyter's Vim mode sucks. VS Code has a great interactive mode with full autocomplete and a dedicated window that records plots/output history.
2. Language servers and LSP plugins are so much easier to manage. I rarely if ever have to babysit updates and I don't have to install a bunch of system-wide dependencies to get certain ones to build.
3. Making the above (and all other fancy VS Code functionality) work on multiple remote machines is a breeze. The normal Vim workflow would require cloning dotfiles (not a big deal), running setup with something like GNU Stow (almost never installed) and then futzing around with LSP plugins as in 2).
4. Built-in rendering of rich docstrings/doc pages (think Markdown, Sphinx RST). I want to say certain extensions/languages support LaTeX as well, which would be a bear to read in Vim.
Re: Vim Creep (2011)
#115Earlier quoted context omitted.
I highly recommend trying out VSCodeVim. Use it for Go, JS, C, Rust and more - it's really enjoyable, and even stuff like C - W works just fine.
Unfortunately that plug-in is a horrible performance hit to an editor that already is on the slow side of typing responsiveness.
Re: Vim Creep (2011)
#116Earlier quoted context omitted.
> I don't understand - how is using a debugger a waste of time? The debugger may help you understand, at some moment in time, what an unclear piece of code does. When you revisit this piece of code later, or another person finds it, your first experience with the debugger is not remembered, thus lost. This is what I meant. On the contrary, if you clarify the code and make it easier to instrumentate (by adding asserti…
I feel like your understanding of a debugger is very limited. To me - A debugger is the instrumentation you're talking about, but created by the language/runtime developers instead of having to be remade by you, poorly, for each new project. A good watch statement is a hell of a lot more useful than an assert - even though they both try to do the same thing. Not even touching the places where a debugger solves a prob…
I've had a fair share of using debuggers in my life, and I ended with my anti-debugging stance as a matter of fatigue, and a sense of time lost. I know what debuggers are capable of, especially regarding data visualization. But for your example of the variable watch, what are you going to watch, precisely? That the value of a variable is always positive? That it increases one by one? All these things are better served by assertions. What kind of information can be inferred by just looking at the evolution of values of a variable that is not easily formalized as an assert or a simple in-code test?
Re: Vim Creep (2011)
#117Earlier quoted context omitted.
> I don't understand - how is using a debugger a waste of time? The debugger may help you understand, at some moment in time, what an unclear piece of code does. When you revisit this piece of code later, or another person finds it, your first experience with the debugger is not remembered, thus lost. This is what I meant. On the contrary, if you clarify the code and make it easier to instrumentate (by adding asserti…
I feel like your understanding of a debugger is very limited. To me - A debugger is the instrumentation you're talking about, but created by the language/runtime developers instead of having to be remade by you, poorly, for each new project. A good watch statement is a hell of a lot more useful than an assert - even though they both try to do the same thing. Not even touching the places where a debugger solves a prob…
Re: Vim Creep (2011)
#118Earlier quoted context omitted.
I don't understand - how is using a debugger a waste of time? I don't often use a debugger, but they have proven to be useful in a lot of cases.
> I don't understand - how is using a debugger a waste of time? The debugger may help you understand, at some moment in time, what an unclear piece of code does. When you revisit this piece of code later, or another person finds it, your first experience with the debugger is not remembered, thus lost. This is what I meant. On the contrary, if you clarify the code and make it easier to instrumentate (by adding asserti…
> by adding [...] comments, [...] etc
If you need a debugger, those are not there or not good enough, and you can only meaningfully add them after you understand what's happening.
(EDIT: there is also a wide variety in what people count as a "debugger" further muddying the debate)
Re: Vim Creep (2011)
#119Earlier quoted context omitted.
There are language servers for Vim that take you much closer to IDEs than you give it credit for. Goto definitions, intelligent autocomplete, inline diagnostics, smart renamers, type hints and more are all available. All with very little configuration and it works the same no matter the language (as long as it as SLP support).
Close but not close enough. For example: in VSCode you can select/hover over any expression and it’ll tell you the computed TypeScript type. None of the current language server tools for Vim (eg ALE) give you that information [0]. Why would I live without this useful feature just to use Vim? I love Vim, but I love knowing the type the TS compiler thinks an expression is even more, especially when good enough Vim emul…
Re: Vim Creep (2011)
#120Truly a great story! Reminds me of this story... Two years ago I was collaborating with a coworker. Most of our time was in his office. I would look over his shoulder as he typed. He had recently adopted a new IDE and spent considerable time configuring it and learning its features. He was very proud of how productive it made him. Then one day we collaborated in my office instead. I use plain Unix tools, all independ…
My .bashrc is on a quest to turn my yakuake into the better half of vscode. "The shell is my IDE" is definitely true. Though Google takes up a worryingly large fraction of it. Wonder if there could be a shell tool to just dump the first stackoverflow hit for a search. bashrc highlights: https://gist.github.com/FeepingCreature/649588a2f6fa27c717bd... - ctrl-G for "directory up" - ctrl-E for "find and open in editor" (…