Is there a documentation of "store-uri" somewhere?


As the title says, I’m looking for reference material for "store-uri"s. In the Nix manual, there are hundreds of references to things that are expected to be "store-uri"s, but I’ve been unable to find the documentation for what a store-uri is. The closest I get is this NixOS issue: Document the store URI syntax · Issue #1556 · NixOS/nix · GitHub but that seems to be missing some entries, in particular the ssh-ng variant that I’m primarily interested in.

There is a new nix help-stores command, but we need to better display that information in the manual.

1 Like

Thanks for the response! I’m not sure how to access this nix help-stores command. I’ve tried calling nix help-stores with Nix from the HEAD of nixpkgs, but there doesn’t appear to be such a command. There’s nix describe-stores, but that command has an odd output that doesn’t seem to be any kind of a documentation.

It’s in the unstable manual: nix help-stores - Nix Reference Manual

Yeah it definitely needs to be presented more conveniently.

1 Like

Thank you very much to you and @Ericson2314 exactly what I was looking for!

Ironically, this page from the manual doesn’t contain the string “store-uri” at all, so even if you search the entire manual for “store-uri” and go through each and every hit, you wouldn’t discover this page :slight_smile:

1 Like

If you have a thoughtful suggestion where to put that information to be easier to discover and otherwise fit in nicely, or even a pull request up your sleeve to implement such change, that would be awesome.

I totally agree that should be addressed, but we simply can’t do all the things at once and have to rely on users who care enough about such things getting improved to actually do some work.

I’m sorry if my comment came across as snarky. I appreciate everything in the Nix ecosystem and I’m grateful to everyone that contributes to it. My intention was to point out a potential room for improvement by mentioning in that page that the store types are also referred to as “store-uri” parameters. This way, that page would at least show up for someone searching for “store-uri” in the manual.

Information discoverability is a very non-trivial problem since everyone comes from a different direction, with different needs and a different mental context. That said, I think it would be helpful for everyone if all the store-uri references in all Nix command pages were links pointing at the help-stores page. I don’t know how hard it would be to make this happen without too much noise in the manual source or how tolerant the community would be to this kind of noise.

I didn’t perceive your comment as snarky at all, no worries. I genuinely appreciate any input and feedback. My response was about the next step, how to practically address the issue you pointed out. I’d just do it myself, and probably will do eventually anyway, but that has no ETA since a ton of other things should be finished first.

The first step would be to re-evaluate if there even should be a stand-alone command that displays documentation. We already have the man pages and the --help flag. Assuming we agree to accommodate the information in one such page, which one should it be? And then reworking the code such that it works as intended. Only then it makes more sense to start sifting through the manual and add links to that central location, which I think is in general a very good idea as the number of useful of cross-references is still too low in the manual.

All such changes are welcome, especially if discussed with maintainers beforehand, and I’d support PRs with reviews.

Yeah don’t worry, @fricklerhandwerk and I don’t like the current location of this stuff as the man page for nix help-stores at all.

Thank you both for your help. I’m probably not the target audience for the man pages since I don’t remember the last time I read the man page for a command. I usually check the online documentation, do a Google search and ask ChatGPT these days. I’d love to open a PR, but I also don’t know when I could get round to doing it.

BTW, speaking of ChatGPT, maybe the solution to all information discoverability problems like this is to fine-tune an AI model on the Nix manuals (and some other Nix materials) and put it somewhere close to the search bar.

Maybe for some aspects, but otherwise quite surely not. The manuals are lacking much basic information, and all the internet’s Nix knowledge taken together is really coarse and partially outdated. Nix itself is not that complicated, in fact I’d say it’s incredibly simple; we’re just not presenting it right – yet. Working on it.

1 Like