summary refs log tree commit diff
path: root/doc
diff options
context:
space:
mode:
authorPasquale <p3dimaria@hotmail.it>2021-11-29 18:59:33 +0100
committerPasquale <p3dimaria@hotmail.it>2021-12-02 21:54:53 +0100
commitd2e237cbe19c70ad3c22956f51846eb0f729be7c (patch)
tree32e8c047dd10ff9d2cc00da34c943b04d5d82341 /doc
parent767d56e8347c2ff2fb95a8dc4f5532ca148afba3 (diff)
downloadnixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.tar
nixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.tar.gz
nixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.tar.bz2
nixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.tar.lz
nixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.tar.xz
nixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.tar.zst
nixpkgs-d2e237cbe19c70ad3c22956f51846eb0f729be7c.zip
concatText: documentation
Diffstat (limited to 'doc')
-rw-r--r--doc/builders/trivial-builders.chapter.md5
1 files changed, 5 insertions, 0 deletions
diff --git a/doc/builders/trivial-builders.chapter.md b/doc/builders/trivial-builders.chapter.md
index c3a3572cd9f..4a2f36ed211 100644
--- a/doc/builders/trivial-builders.chapter.md
+++ b/doc/builders/trivial-builders.chapter.md
@@ -47,6 +47,11 @@ These functions write `text` to the Nix store. This is useful for creating scrip
 
 Many more commands wrap `writeTextFile` including `writeText`, `writeTextDir`, `writeScript`, and `writeScriptBin`. These are convenience functions over `writeTextFile`.
 
+## `concatTextFile`, `concatText`, `concatScript` {#trivial-builder-concatText}
+
+These functions concatenate `files` to the Nix store in a single file. This is useful for configuration files structured in lines of text. `concatTextFile` takes an attribute set and expects two arguments, `name` and `files`. `name` corresponds to the name used in the Nix store path. `files` will be the files to be concatenated. You can also set `executable` to true to make this file have the executable bit set.
+`concatText` and`concatScript` are simple wrappers over `concatTextFile`.
+
 ## `writeShellApplication` {#trivial-builder-writeShellApplication}
 
 This can be used to easily produce a shell script that has some dependencies (`runtimeInputs`). It automatically sets the `PATH` of the script to contain all of the listed inputs, sets some sanity shellopts (`errexit`, `nounset`, `pipefail`), and checks the resulting script with [`shellcheck`](https://github.com/koalaman/shellcheck).