nix3-store...-hash-part(1)

πŸ’– nix3-store...-hash-part(1) πŸ’–

okay bestie, grab your matcha because we're diving into the General Commands Manual and this one is a lil cutie. it's nix store path-from-hash-part, and yes the title is giving "why are there dots" but it's iconic, trust. πŸŽ€

⚠️ Warning β€” this program is experimental and its interface is subject to change. so like, don't build your whole personality on it, okay? πŸ™ˆ

✨ Name ✨

nix store path-from-hash-part β€” get a store path from its hash part πŸ¦‹

lowkey that's the whole job. she does one thing and she does it well.


🌸 Synopsis 🌸

nix store path-from-hash-part [option…] hash-part

πŸ“ Examples πŸ“

  • Return the full store path with the given hash part:
# nix store path-from-hash-part --store https://cache.nixos.org/ qbhyj3blxpw2i6pb7c6grc9185nbnpvy
/nix/store/qbhyj3blxpw2i6pb7c6grc9185nbnpvy-hello-2.10

not her turning 32 little characters into a whole entire path, main character energy fr fr πŸ‘‘


πŸ’œ Description πŸ’œ

so here's the vibe: you hand her the hash part of a store path β€” that's the 32 characters that come right after /nix/store/ β€” and she hands you back the full store path. glow-up complete. ✨

where does this actually matter? it's primarily useful in the implementation of binary caches, because when something asks for a .narinfo file, the request only supplies the hash part. like this:

https://cache.nixos.org/qbhyj3blxpw2i6pb7c6grc9185nbnpvy.narinfo

see? just the hash part, no path, no vibe check. that's her moment. 🫢


πŸŽ€ Options πŸŽ€

  • --debug β€” set the logging verbosity level to β€˜debug’. she's telling you everything, no secrets, we love an over-sharer. πŸ’…
  • --log-format format β€” set the format of log output; one of raw, internal-json, bar or bar-with-logs. pick your aesthetic bestie. 🌈
  • --print-build-logs, -L β€” print full build logs on standard error.
  • --quiet β€” decrease the logging verbosity level. shhh. 🀫
  • --verbose, -v β€” increase the logging verbosity level. louder!! πŸ“’

Miscellaneous global options

  • --help β€” show usage information. when in doubt, ask her directly. πŸ’–
  • --offline β€” disable substituters and consider all previously downloaded files up-to-date.
  • --option name value β€” set the Nix configuration setting name to value (overriding nix.conf).
  • --refresh β€” consider all previously downloaded files out-of-date.
  • --version β€” show version information.
πŸ“ Note β€” see man nix.conf for overriding configuration settings with command line flags. iykyk. 🧚

and that's the whole page bestie, we ate and left absolutely no crumbs. πŸ“βœ¨ this came from the General Commands Manual, page nix3-store...-hash-part(1) β€” no cap, go forth and resolve those hash parts. bye pookie, slay responsibly πŸ’œπŸ‘‘

πŸ“¦ where this page comes from