Cheatsheet: Difference between revisions
imported>Gzorg m →Get the store path for a package: Fix typo |
imported>Mic92 nix-env on full store paths |
||
| Line 505: | Line 505: | ||
=== Download a nix store path from the cache === | === Download a nix store path from the cache === | ||
If you want to the exact same nix store path on a different system, you can use the | If you want to the exact same nix store path on a different system, you can use the <code>--realise</code> or short <code>-r</code> parameter in the <code>nix-store</code> command: | ||
<syntaxHighlight lang="console"> | <syntaxHighlight lang="console"> | ||
| Line 518: | Line 518: | ||
</syntaxHighlight> | </syntaxHighlight> | ||
=== Install an arbitrary nix store path into a user profile === | |||
<code>nix-env</code> also accepts the full path to a program in the nix store: | |||
<syntaxHighlight lang="console"> | |||
$ nix-env -i /nix/store/yzz2gvpcyxg5i68zi11sznbsp1ypccz8-firefox-65.0 | |||
</syntaxHighlight> | |||
== See also == | == See also == | ||
* [[Garbage Collection]] | * [[Garbage Collection]] | ||
* [[NFS#Nix_store_on_NFS|Nix store on NFS]] | * [[NFS#Nix_store_on_NFS|Nix store on NFS]] | ||