wiki/cli.niv.html
2022-07-29 15:41:17 +00:00

18 lines
7.2 KiB
HTML

<!DOCTYPE html><html><head><meta name="viewport" content="width=device-width"/><meta charSet="utf-8"/><title>Command line: Niv</title><script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script><script id="MathJax-script" async="" src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script><script type="text/x-mathjax-config">
MathJax = {
tex: {
inlineMath: [ [&#x27;$&#x27;,&#x27;$&#x27;], [&#x27;\(&#x27;,&#x27;\)&#x27;] ],
displayMath: [ [&#x27;$$&#x27;,&#x27;$$&#x27;], [&#x27;[&#x27;,&#x27;]&#x27;] ]
},
options = {
processHtmlClass = &quot;math&quot;
}
}
</script><meta name="next-head-count" content="6"/><link rel="preload" href="/wiki/_next/static/css/52fc2ba29703df73922c.css" as="style"/><link rel="stylesheet" href="/wiki/_next/static/css/52fc2ba29703df73922c.css" data-n-g=""/><noscript data-n-css=""></noscript><link rel="preload" href="/wiki/_next/static/chunks/main-ae4733327bd95c4ac325.js" as="script"/><link rel="preload" href="/wiki/_next/static/chunks/webpack-50bee04d1dc61f8adf5b.js" as="script"/><link rel="preload" href="/wiki/_next/static/chunks/framework.9d524150d48315f49e80.js" as="script"/><link rel="preload" href="/wiki/_next/static/chunks/commons.0e1c3f9aa780c2dfe9f0.js" as="script"/><link rel="preload" href="/wiki/_next/static/chunks/pages/_app-8e3d0c58a60ec788aa69.js" as="script"/><link rel="preload" href="/wiki/_next/static/chunks/940643274e605e7596ecea1f2ff8d83317a3fb76.4841a16762f602a59f00.js" as="script"/><link rel="preload" href="/wiki/_next/static/chunks/pages/%5B%5B...slug%5D%5D-1aa198f87ede1cd0e1dc.js" as="script"/></head><body><div id="__next"><main><h1>Command line: Niv</h1><section class="post-metadata"><span>Date: <!-- -->2021-05-09 17:25:04 +08:00</span><span>Date modified: <!-- -->2021-06-19 17:43:28 +08:00</span></section><nav class="toc"><ol class="toc-level toc-level-1"></ol></nav><p>niv is a template generator for a quick start of creating a Nix environment with full reproducibility.
It allows for a quick configuration of where to pin certain package sets (e.g., nixpkgs, NUR, your own package set) with a command line program.
</p><ul><li><p><code class="inline-code">niv init</code></p></li><li><p>Configuring your pins with <code class="inline-code">niv show $SOURCE</code> and editing <code class="inline-verbatim">nix/sources.json</code> generated from <code class="inline-code">niv init</code>.
</p></li><li><p>Using it by importing from your Nix files (e.g., <code class="inline-verbatim">default.nix</code>, <code class="inline-verbatim">shell.nix</code>).
</p></li></ul><p>You can also update the pins with <code class="inline-code">niv update $SOURCE</code> and you don&#x27;t have to manually look into the repo for updating the pins.
Though, Nix flakes are still the more attractive options IMO.
</p><p>If you&#x27;re looking to update the official channels, you can take a peek at <a href="https://status.nixos.org/">status.nixos.org</a>.
</p></main></div><script id="__NEXT_DATA__" type="application/json">{"props":{"pageProps":{"metadata":{"date":"\"2021-05-09 17:25:04 +08:00\"","date_modified":"\"2021-06-19 17:43:28 +08:00\"","language":"en","source":""},"title":"Command line: Niv","hast":{"type":"root","children":[{"type":"element","tagName":"nav","properties":{"className":"toc"},"children":[{"type":"element","tagName":"ol","properties":{"className":"toc-level toc-level-1"},"children":[]}]},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"niv is a template generator for a quick start of creating a Nix environment with full reproducibility.\nIt allows for a quick configuration of where to pin certain package sets (e.g., nixpkgs, NUR, your own package set) with a command line program.\n"}]},{"type":"element","tagName":"ul","properties":{},"children":[{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"p","properties":{},"children":[{"type":"element","tagName":"code","properties":{"className":["inline-code"]},"children":[{"type":"text","value":"niv init"}]}]}]},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"Configuring your pins with "},{"type":"element","tagName":"code","properties":{"className":["inline-code"]},"children":[{"type":"text","value":"niv show $SOURCE"}]},{"type":"text","value":" and editing "},{"type":"element","tagName":"code","properties":{"className":["inline-verbatim"]},"children":[{"type":"text","value":"nix/sources.json"}]},{"type":"text","value":" generated from "},{"type":"element","tagName":"code","properties":{"className":["inline-code"]},"children":[{"type":"text","value":"niv init"}]},{"type":"text","value":".\n"}]}]},{"type":"element","tagName":"li","properties":{},"children":[{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"Using it by importing from your Nix files (e.g., "},{"type":"element","tagName":"code","properties":{"className":["inline-verbatim"]},"children":[{"type":"text","value":"default.nix"}]},{"type":"text","value":", "},{"type":"element","tagName":"code","properties":{"className":["inline-verbatim"]},"children":[{"type":"text","value":"shell.nix"}]},{"type":"text","value":").\n"}]}]}]},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"You can also update the pins with "},{"type":"element","tagName":"code","properties":{"className":["inline-code"]},"children":[{"type":"text","value":"niv update $SOURCE"}]},{"type":"text","value":" and you don't have to manually look into the repo for updating the pins.\nThough, Nix flakes are still the more attractive options IMO.\n"}]},{"type":"element","tagName":"p","properties":{},"children":[{"type":"text","value":"If you're looking to update the official channels, you can take a peek at "},{"type":"element","tagName":"a","properties":{"href":"https://status.nixos.org/"},"children":[{"type":"text","value":"status.nixos.org"}]},{"type":"text","value":".\n"}]}]},"backlinks":[]},"__N_SSG":true},"page":"/[[...slug]]","query":{"slug":["cli.niv"]},"buildId":"Ie9t5zutrXP6Of75Cb5xF","assetPrefix":"/wiki","nextExport":false,"isFallback":false,"gsp":true}</script><script nomodule="" src="/wiki/_next/static/chunks/polyfills-99d808df29361cf7ffb1.js"></script><script src="/wiki/_next/static/chunks/main-ae4733327bd95c4ac325.js" async=""></script><script src="/wiki/_next/static/chunks/webpack-50bee04d1dc61f8adf5b.js" async=""></script><script src="/wiki/_next/static/chunks/framework.9d524150d48315f49e80.js" async=""></script><script src="/wiki/_next/static/chunks/commons.0e1c3f9aa780c2dfe9f0.js" async=""></script><script src="/wiki/_next/static/chunks/pages/_app-8e3d0c58a60ec788aa69.js" async=""></script><script src="/wiki/_next/static/chunks/940643274e605e7596ecea1f2ff8d83317a3fb76.4841a16762f602a59f00.js" async=""></script><script src="/wiki/_next/static/chunks/pages/%5B%5B...slug%5D%5D-1aa198f87ede1cd0e1dc.js" async=""></script><script src="/wiki/_next/static/Ie9t5zutrXP6Of75Cb5xF/_buildManifest.js" async=""></script><script src="/wiki/_next/static/Ie9t5zutrXP6Of75Cb5xF/_ssgManifest.js" async=""></script></body></html>