From c1b05442ffd6cf3cf529cad469bebe8169b156e9 Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Sun, 20 Sep 2020 00:59:03 +0200 Subject: [PATCH] doc: Undocument attr-set of passthru.updateScript We no longer need it for most use cases so I am making it experimental. I have something in mind where it might be useful in the future (customizing commit messages) but for now, it would only confuse people. --- doc/stdenv/stdenv.xml | 43 ------------------------------------------- 1 file changed, 43 deletions(-) diff --git a/doc/stdenv/stdenv.xml b/doc/stdenv/stdenv.xml index 6962c57a6ac..d33ee382d0b 100644 --- a/doc/stdenv/stdenv.xml +++ b/doc/stdenv/stdenv.xml @@ -474,14 +474,6 @@ passthru.updateScript = writeScript "update-zoom-us" '' The attribute can also contain a list, a script followed by arguments to be passed to it: passthru.updateScript = [ ../../update.sh pname "--requested-release=unstable" ]; - - Finally, the attribute can be an attribute set, listing the attribute path and extra supported features in addition to command. - -passthru.updateScript = { - command = [ ../../update.sh pname ]; - attrPath = pname; - supportedFeatures = [ … ]; -}; @@ -489,41 +481,6 @@ passthru.updateScript = { - - maintainers/scripts/update.nix also supports automatically creating commits by running it with --argstr commit true. Neither declaring the attrPath attribute, or adding a commit to supportedFeatures and modifying the script accordingly is required. It might be useful if you want to customize the values to something else than what update.nix detects. - - - Supported features - - - commit - - - - Whenever the update script exits with 0 return - status, it is expected to print a JSON list containing an object for - each updated attribute. Empty list can be returned when the script did - not update any files: for example, when the attribute is already the - latest version. The required keys can be seen below: - -[ - { - "attrPath": "volume_key", - "oldVersion": "0.3.11", - "newVersion": "0.3.12", - "files": [ - "/path/to/nixpkgs/pkgs/development/libraries/volume-key/default.nix" - ] - } -] - - - - When the returned array contains exactly one object (e.g. [{}]), keys can be omitted and will be determined automatically. Finding out newVersion requires attrPath to be present either in the update script output or passed to the passthru.updateScript attribute set. - - - - For information about how to run the updates, execute nix-shell maintainers/scripts/update.nix.