Live data from Hacker News

Rust, RR, Neovim: A perfect debug combination

github.com

21–30 of 102 posts

Re: Rust, RR, Neovim: A perfect debug combination

#21

Anyone got other useful tools for debugging within (neo)vim? Just seamlessly putting down breakpoints, stepping through code execution, and getting a fully fledged debugging UI experience (a la Visual Studio or Remedy BG)? This is possibly the only thing I miss from developing on Windows, and it's a shame! EDIT: I specified 'within vim' but actually I'd be down for standalone Linux app recommendations too.

I use nvim-dap[1] in combination with jester[2] (by me) to run and debug Jest tests in my project, it works perfectly.

[1]: https://github.com/mfussenegger/nvim-dap

[2]: https://github.com/David-Kunz/jester

Re: Rust, RR, Neovim: A perfect debug combination

#23

Anyone got other useful tools for debugging within (neo)vim? Just seamlessly putting down breakpoints, stepping through code execution, and getting a fully fledged debugging UI experience (a la Visual Studio or Remedy BG)? This is possibly the only thing I miss from developing on Windows, and it's a shame! EDIT: I specified 'within vim' but actually I'd be down for standalone Linux app recommendations too.

VS code plus its vim key binding plugin. The neovim plugin world is just way too unstable in my experience.

Re: Rust, RR, Neovim: A perfect debug combination

#26
I personally have never used a debugger in Rust. Logging and printing has typically been enough.

For those use cases where it is tough to see the output (tests, windows services, etc.) I wrote the `rdbg` set of crates. It is essentially identical to `dbg!` and `println!` macros, but delivers messages via a TCP socket to a simple command-line viewer (which can be on the same machine or remote). The design is such that it can be enabled and used the first time within a minute or two for "quick and dirty debugging". It can just as quickly be removed or turned into a no-op with a Rust feature.

Dependency: https://crates.io/crates/rdbg

Viewer: https://crates.io/crates/rdbg-view

EDIT: Apparently I need to update the README as I added the 'msgf' and 'valsf' macros that include auto-flush which is handy for short running programs where explicit flush doesn't work due to failing program/etc.

Re: Rust, RR, Neovim: A perfect debug combination

#27

[flagged]

We, the R-word foundation, hereby and publically do not endorse the online gathering under this comment, as it does not:

- follow local health guidelines

- may attract people wearing fireguns

These breaches of our big CoC are not appreciated and we will spend all of our sparse funding now to drag you to court.

Re: Rust, RR, Neovim: A perfect debug combination

#28
post #27

[flagged]

We, the R-word foundation, hereby and publically do not endorse the online gathering under this comment, as it does not: - follow local health guidelines - may attract people wearing fireguns These breaches of our big CoC are not appreciated and we will spend all of our sparse funding now to drag you to court.

I just hope Rust won't end up being forked tho. We had such an amazing community around it...
Post reply on HN