From 5729cfb4a7b71f3da8df7b7b92cfafb8d7738813 Mon Sep 17 00:00:00 2001 From: Daniel Barlow Date: Thu, 9 Nov 2023 22:12:29 +0000 Subject: [PATCH] document installation methods (only vmroot yet) --- ci.nix | 1 + doc/index.rst | 1 + doc/installers.rst | 8 ++++++++ doc/parse-options-outputs.fnl | 11 +++++++++++ 4 files changed, 21 insertions(+) create mode 100644 doc/installers.rst create mode 100644 doc/parse-options-outputs.fnl diff --git a/ci.nix b/ci.nix index 4e901ed..649ef0f 100644 --- a/ci.nix +++ b/ci.nix @@ -47,6 +47,7 @@ let src = ./.; buildPhase = '' cat ${json} | fennel --correlate doc/parse-options.fnl > doc/modules-generated.rst + cat ${json} | fennel --correlate doc/parse-options-outputs.fnl system.outputs.vmroot > doc/installers-generated.rst cp ${(import ./doc/hardware.nix)} doc/hardware.rst make -C doc html ''; diff --git a/doc/index.rst b/doc/index.rst index 6e4e61f..d474c34 100644 --- a/doc/index.rst +++ b/doc/index.rst @@ -12,6 +12,7 @@ Liminix development modules hardware + installers Indices and tables diff --git a/doc/installers.rst b/doc/installers.rst new file mode 100644 index 0000000..5b8f548 --- /dev/null +++ b/doc/installers.rst @@ -0,0 +1,8 @@ +Installers +########## + +There are a number of different routes to getting +Liminix onto devices, and which one you should use +(or are able to use) varies according to the device. + +.. include:: installers-generated.rst diff --git a/doc/parse-options-outputs.fnl b/doc/parse-options-outputs.fnl new file mode 100644 index 0000000..55f0ed3 --- /dev/null +++ b/doc/parse-options-outputs.fnl @@ -0,0 +1,11 @@ +(local yaml (require :lyaml)) + +;; (local { : view } (require :fennel)) + +(local outputs (collect [k v (ipairs arg)] + (values v true))) + +(each [_ option (ipairs (yaml.load (io.read "*a")))] + (when (. outputs option.name) + (print (.. ".. _" option.name) "\n") + (print option.description)))