aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2018-07-13 13:52:22 +0200
committertv <tv@krebsco.de>2018-07-13 13:53:46 +0200
commitc47d8972ad29f80472e9778e6db76838dd8c0cd3 (patch)
tree327a572ad696b75b8fa161f7d358baba15db6591
parentdb6151ff06777deb05b345f1775c037d8671687d (diff)
move disko.nix to example/ and add usage
-rw-r--r--example/config.nix (renamed from example.nix)2
-rw-r--r--example/default.nix (renamed from disko.nix)4
2 files changed, 4 insertions, 2 deletions
diff --git a/example.nix b/example/config.nix
index 38830b6..e9766fe 100644
--- a/example.nix
+++ b/example/config.nix
@@ -1,4 +1,4 @@
-# nix-instantiate --strict --json --eval format.nix | jq
+# usage: nix-instantiate --eval --json --strict example/config.nix | jq .
{
type = "table";
format = "gpt";
diff --git a/disko.nix b/example/default.nix
index 2e6805a..69ef936 100644
--- a/disko.nix
+++ b/example/default.nix
@@ -1,3 +1,5 @@
+# usage: nix-instantiate --eval --json --strict example | jq -r .
+
with import <nixpkgs/lib>;
with builtins;
@@ -47,6 +49,6 @@ let
f = q: x: fun.${x.type} q x;
q0.device = "/dev/sda";
- x0 = import ./example.nix;
+ x0 = import ./config.nix;
in
f q0 x0