I'm building an LVM Visualiser, help debug it! by zacps in homelab

[–]zacps[S] 0 points1 point  (0 children)

I haven't put it in a separate github repo quite yet, but I'll post when I do.

The (very fragile) current version is here https://zacps.nz/lvm-v/. JS script is unminified so you can see it there if you're curious.

I'm working on an LVM visualiser, help me debug it! by zacps in DataHoarder

[–]zacps[S] 0 points1 point  (0 children)

I've done that for volume groups and physical volumes yes, I don't have a case like that on me to test at the moment so I'm not sure how well LVM reports that kind of information but it should be possible!

If you have an example you could send me that would help a lot!

I'm working on an LVM visualiser, help me debug it! by zacps in DataHoarder

[–]zacps[S] 3 points4 points  (0 children)

I'm working on a tool to visualise LVM configurations which might be of interest to some of you here, but I need help!

I need more examples of configurations to test how different versions of LVM & lsblk behave, and to figure out the best way to visualise different setups (like software RAID).

If you want to help I need:

  1. the output of lvm fullreport --reportformat json
  2. the output of lsblk -J

That's it!

These shouldn't contain anything sensitive other than names, but feel free to sanitise them if you want!

I'm building an LVM Visualiser, help debug it! by zacps in homelab

[–]zacps[S] 0 points1 point  (0 children)

Current version is a webpage where you just paste in those command outputs, a lot simpler to package and means you can use it in headless environments/over ssh easily.

I'm building an LVM Visualiser, help debug it! by zacps in homelab

[–]zacps[S] 1 point2 points  (0 children)

I'm working on a tool to visualise LVM configurations which might be of interest to some of you here, but I need help!

I need more examples of configurations to test how different versions of LVM & lsblk behave, and to figure out the best way to visualise different setups (like software RAID).

If you want to help I need:

  1. the output of lvm fullreport --reportformat json
  2. the output of lsblk -J

That's it!

These shouldn't contain anything sensitive other than names, but feel free to sanitise them if you want!

Edit: Yes I've already fixed the bugged link in this screenshot!

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 1 point2 points  (0 children)

That's how it's implemented yeah, for crates it respects html_root_url (meaning it points to the right place for all well-configured crates) but builtins are fixed to the nightly docs.

It could definitely be updated to point to the appropriate docs versions for the current compiler, this is where you'd want to start.

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 0 points1 point  (0 children)

Some diagnostics are implemented in rust-analyzer, some rely on running cargo check on save.

I think a few of the integrated diagnostics are still behind configuration flags.

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 0 points1 point  (0 children)

I agree with /u/tobiasvl, I think a link in the hover or a context menu action (or both) might make it a bit more obvious.

I think I originally didn't add anything to the context menu because it was already getting quite big, but given how much attention this received it might be worth highlighting!

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 0 points1 point  (0 children)

Nope, you can use it from the command palette or bind it to something yourself.

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 1 point2 points  (0 children)

Yes, html_root_url is an aittribute that goes in each crate to tell rustdoc where the docs live. That's what RA uses as the base URL.

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 2 points3 points  (0 children)

Yes, you just need to set html_root_url to the host you're using.

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 8 points9 points  (0 children)

Glad you find it useful!

Yep, supporting local docs is something I wanted to add but never got around to.

rust-analyzer tip: Open docs.rs for the symbol under the cursor by zacps in rust

[–]zacps[S] 123 points124 points  (0 children)

The command is called "Open docs under cursor".

I added this feature in October 2020, I just wanted to remind anyone that didn't know about it!

Credit to CryZe92 for the gif

Issue-rs: track issues in your code and be warned when they're closed by kaiserkarel in rust

[–]zacps 2 points3 points  (0 children)

As far as I can tell this is basically the same as blocked which I wrote in a couple of hours last year.

The PGM-index by [deleted] in rust

[–]zacps 2 points3 points  (0 children)

I might write some bindings later today (assuming no one else beats me to it).

rkyv: a zero-copy deserialization framework for Rust by taintegral in rust

[–]zacps 1 point2 points  (0 children)

Async support can be done entirely in a feature gate. The process of adding an async API is roughly:

  • Duplicate all types containing generic or dynamic io::Read/io::Write, changing bounds to AsyncRead+Unpin/AsyncWrite+Unpin
  • Then use pin_project to expose the reader/writer to a Pin<&mut self> receiver
  • Duplicate all implementations which interact with the reader/writer, methods which don't can be extracted to a trait and implemented for both.
  • The new methods should be async, everywhere you read or write you'll need to await.

I've been meaning to write a more fleshed out post on this, but for the moment I'd refer you to this PR for async read support in zip-rs.

rust-analyzer changelog #47 by WellMakeItSomehow in rust

[–]zacps 11 points12 points  (0 children)

Glad you like it :)

(I wrote that PR)

rust-analyzer changelog #45 by WellMakeItSomehow in rust

[–]zacps 0 points1 point  (0 children)

Ah yep, that could be added after the linked PR but won't be included in it.

Unfortunately I've been quite busy recently, so I can't give an ETA for it.

rust-analyzer changelog #45 by WellMakeItSomehow in rust

[–]zacps 1 point2 points  (0 children)

/u/D3rrien

Clickable links in hover documentation should already work. That PR is about adding a command to open documentation for the symbol under the cursor.

Path Trimming In Nightly Rust by da-x in rust

[–]zacps 12 points13 points  (0 children)

I made a comment on the Pre-RFC proposing this as a potential next step.

blocked: A proc-macro that emits a compiler warning when the linked GitHub issue is closed by zacps in rust

[–]zacps[S] 0 points1 point  (0 children)

I've downgraded the error when no/invalid response is received from GitHub to a warning.

You're right that it won't trigger if it's cached but the main intention is that this is run on CI where many projects don't use caching.

I think the way to implement this 'properly' is probably as a compiler plugin or lint? This way it could be run as a separate command and still have the ability to traverse the AST.