From ea3e29fe7d02e2d951c9deea93057330d0e18fec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Thalheim?= Date: Fri, 15 Sep 2023 07:53:30 +0200 Subject: [PATCH] update command line reference --- docs/reference.md | 27 ++++++++++++++++++++------- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/docs/reference.md b/docs/reference.md index 3c49a6b..d5be846 100644 --- a/docs/reference.md +++ b/docs/reference.md @@ -2,29 +2,42 @@ ## Module Options -TODO: Still to be documented +We are currently having issues beeing able to generate proper +module option documentation for our recursive disko types. +However you can read the available options [here](https://github.com/nix-community/disko/tree/master/lib/types). +Combined wit the [examples](https://github.com/nix-community/disko/tree/master/example) this hopefully gives you an overview. ## # Reference Manual: disko ## Command Line Options ``` -$ nix run github:nix-community/disko -- -disko [options] disk-config.nix -or disko [options] --flake github:somebody/somewhere +Usage: ./disko [options] disk-config.nix +or ./disko [options] --flake github:somebody/somewhere#disk-config + +With flakes, disk-config is discovered first under the .diskoConfigurations top level attribute +or else from the disko module of a NixOS configuration of that name under .nixosConfigurations. + Options: + * -m, --mode mode - set the mode, either create or mount + set the mode, either format, mount or disko + format: create partition tables, zpools, lvms, raids and filesystems + mount: mount the partition at the specified root-mountpoint + disko: first unmount and destroy all filesystems on the disks we want to format, then run the create and mount mode * -f, --flake uri fetch the disko config relative to this flake's root * --arg name value pass value to nix-build. can be used to set disk-names for example * --argstr name value pass value to nix-build as string -* --root-mountpoint /mnt - where to mount the device tree +* --root-mountpoint /some/other/mnt + where to mount the device tree (default: /mnt) * --dry-run just show the path to the script instead of running it +* --no-deps + avoid adding another dependency closure to an in-memory installer + requires all necessary dependencies to be available in the environment * --debug run with set -x ```