Project import generated by Copybara.
GitOrigin-RevId: 5e2018f7b383aeca6824a30c0cd1978c9532a46a
This commit is contained in:
parent
818c48e259
commit
5e2a688410
979 changed files with 7394 additions and 5295 deletions
1
third_party/nixpkgs/.github/CODEOWNERS
vendored
1
third_party/nixpkgs/.github/CODEOWNERS
vendored
|
@ -65,6 +65,7 @@
|
||||||
/nixos/doc/manual/development/writing-modules.xml @nbp
|
/nixos/doc/manual/development/writing-modules.xml @nbp
|
||||||
/nixos/doc/manual/man-nixos-option.xml @nbp
|
/nixos/doc/manual/man-nixos-option.xml @nbp
|
||||||
/nixos/modules/installer/tools/nixos-option.sh @nbp
|
/nixos/modules/installer/tools/nixos-option.sh @nbp
|
||||||
|
/nixos/modules/system @dasJ
|
||||||
|
|
||||||
# NixOS integration test driver
|
# NixOS integration test driver
|
||||||
/nixos/lib/test-driver @tfc
|
/nixos/lib/test-driver @tfc
|
||||||
|
|
|
@ -28,6 +28,10 @@ jobs:
|
||||||
pairs:
|
pairs:
|
||||||
- from: master
|
- from: master
|
||||||
into: haskell-updates
|
into: haskell-updates
|
||||||
|
- from: release-21.05
|
||||||
|
into: staging-next-21.05
|
||||||
|
- from: staging-next-21.05
|
||||||
|
into: staging-21.05
|
||||||
name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
|
name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
|
@ -30,10 +30,6 @@ jobs:
|
||||||
into: staging-next
|
into: staging-next
|
||||||
- from: staging-next
|
- from: staging-next
|
||||||
into: staging
|
into: staging
|
||||||
- from: release-21.05
|
|
||||||
into: staging-next-21.05
|
|
||||||
- from: staging-next-21.05
|
|
||||||
into: staging-21.05
|
|
||||||
name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
|
name: ${{ matrix.pairs.from }} → ${{ matrix.pairs.into }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
18
third_party/nixpkgs/doc/builders/packages/etc-files.section.md
vendored
Normal file
18
third_party/nixpkgs/doc/builders/packages/etc-files.section.md
vendored
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
# /etc files {#etc}
|
||||||
|
|
||||||
|
Certain calls in glibc require access to runtime files found in /etc such as `/etc/protocols` or `/etc/services` -- [getprotobyname](https://linux.die.net/man/3/getprotobyname) is one such function.
|
||||||
|
|
||||||
|
On non-NixOS distributions these files are typically provided by packages (i.e. [netbase](https://packages.debian.org/sid/netbase)) if not already pre-installed in your distribution. This can cause non-reproducibility for code if they rely on these files being present.
|
||||||
|
|
||||||
|
If [iana-etc](https://hydra.nixos.org/job/nixos/trunk-combined/nixpkgs.iana-etc.x86_64-linux) is part of your _buildInputs_ then it will set the environment varaibles `NIX_ETC_PROTOCOLS` and `NIX_ETC_SERVICES` to the corresponding files in the package through a _setup-hook_.
|
||||||
|
|
||||||
|
|
||||||
|
```bash
|
||||||
|
> nix-shell -p iana-etc
|
||||||
|
|
||||||
|
[nix-shell:~]$ env | grep NIX_ETC
|
||||||
|
NIX_ETC_SERVICES=/nix/store/aj866hr8fad8flnggwdhrldm0g799ccz-iana-etc-20210225/etc/services
|
||||||
|
NIX_ETC_PROTOCOLS=/nix/store/aj866hr8fad8flnggwdhrldm0g799ccz-iana-etc-20210225/etc/protocols
|
||||||
|
```
|
||||||
|
|
||||||
|
Nixpkg's version of [glibc](https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/libraries/glibc/default.nix) has been patched to check for the existence of these environment variables. If the environment variable are *not set*, then it will attempt to find the files at the default location within _/etc_.
|
|
@ -17,6 +17,7 @@
|
||||||
<xi:include href="kakoune.section.xml" />
|
<xi:include href="kakoune.section.xml" />
|
||||||
<xi:include href="linux.section.xml" />
|
<xi:include href="linux.section.xml" />
|
||||||
<xi:include href="locales.section.xml" />
|
<xi:include href="locales.section.xml" />
|
||||||
|
<xi:include href="etc-files.section.xml" />
|
||||||
<xi:include href="nginx.section.xml" />
|
<xi:include href="nginx.section.xml" />
|
||||||
<xi:include href="opengl.section.xml" />
|
<xi:include href="opengl.section.xml" />
|
||||||
<xi:include href="shell-helpers.section.xml" />
|
<xi:include href="shell-helpers.section.xml" />
|
||||||
|
|
|
@ -181,6 +181,21 @@
|
||||||
rev = "${version}";
|
rev = "${version}";
|
||||||
```
|
```
|
||||||
|
|
||||||
|
- Filling lists condionally _should_ be done with `lib.optional(s)` instead of using `if cond then [ ... ] else null` or `if cond then [ ... ] else [ ]`.
|
||||||
|
|
||||||
|
```nix
|
||||||
|
buildInputs = lib.optional stdenv.isDarwin iconv;
|
||||||
|
```
|
||||||
|
|
||||||
|
instead of
|
||||||
|
|
||||||
|
```nix
|
||||||
|
buildInputs = if stdenv.isDarwin then [ iconv ] else null;
|
||||||
|
```
|
||||||
|
|
||||||
|
As an exception, an explicit conditional expression with null can be used when fixing a important bug without triggering a mass rebuild.
|
||||||
|
If this is done a follow up pull request _should_ be created to change the code to `lib.optional(s)`.
|
||||||
|
|
||||||
- Arguments should be listed in the order they are used, with the exception of `lib`, which always goes first.
|
- Arguments should be listed in the order they are used, with the exception of `lib`, which always goes first.
|
||||||
|
|
||||||
## Package naming {#sec-package-naming}
|
## Package naming {#sec-package-naming}
|
||||||
|
|
10
third_party/nixpkgs/flake.nix
vendored
10
third_party/nixpkgs/flake.nix
vendored
|
@ -11,15 +11,7 @@
|
||||||
|
|
||||||
lib = import ./lib;
|
lib = import ./lib;
|
||||||
|
|
||||||
systems = [
|
systems = lib.systems.supported.hydra;
|
||||||
"x86_64-linux"
|
|
||||||
"i686-linux"
|
|
||||||
"x86_64-darwin"
|
|
||||||
"aarch64-linux"
|
|
||||||
"armv6l-linux"
|
|
||||||
"armv7l-linux"
|
|
||||||
"aarch64-darwin"
|
|
||||||
];
|
|
||||||
|
|
||||||
forAllSystems = f: lib.genAttrs systems (system: f system);
|
forAllSystems = f: lib.genAttrs systems (system: f system);
|
||||||
|
|
||||||
|
|
4
third_party/nixpkgs/lib/default.nix
vendored
4
third_party/nixpkgs/lib/default.nix
vendored
|
@ -123,8 +123,8 @@ let
|
||||||
inherit (self.options) isOption mkEnableOption mkSinkUndeclaredOptions
|
inherit (self.options) isOption mkEnableOption mkSinkUndeclaredOptions
|
||||||
mergeDefaultOption mergeOneOption mergeEqualOption getValues
|
mergeDefaultOption mergeOneOption mergeEqualOption getValues
|
||||||
getFiles optionAttrSetToDocList optionAttrSetToDocList'
|
getFiles optionAttrSetToDocList optionAttrSetToDocList'
|
||||||
scrubOptionValue literalExample showOption showFiles
|
scrubOptionValue literalExpression literalExample literalDocBook
|
||||||
unknownModule mkOption;
|
showOption showFiles unknownModule mkOption;
|
||||||
inherit (self.types) isType setType defaultTypeMerge defaultFunctor
|
inherit (self.types) isType setType defaultTypeMerge defaultFunctor
|
||||||
isOptionType mkOptionType;
|
isOptionType mkOptionType;
|
||||||
inherit (self.asserts)
|
inherit (self.asserts)
|
||||||
|
|
24
third_party/nixpkgs/lib/options.nix
vendored
24
third_party/nixpkgs/lib/options.nix
vendored
|
@ -54,7 +54,7 @@ rec {
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
mkOption { } // => { _type = "option"; }
|
mkOption { } // => { _type = "option"; }
|
||||||
mkOption { defaultText = "foo"; } // => { _type = "option"; defaultText = "foo"; }
|
mkOption { default = "foo"; } // => { _type = "option"; default = "foo"; }
|
||||||
*/
|
*/
|
||||||
mkOption =
|
mkOption =
|
||||||
{
|
{
|
||||||
|
@ -212,11 +212,25 @@ rec {
|
||||||
else x;
|
else x;
|
||||||
|
|
||||||
|
|
||||||
/* For use in the `example` option attribute. It causes the given
|
/* For use in the `defaultText` and `example` option attributes. Causes the
|
||||||
text to be included verbatim in documentation. This is necessary
|
given string to be rendered verbatim in the documentation as Nix code. This
|
||||||
for example values that are not simple values, e.g., functions.
|
is necessary for complex values, e.g. functions, or values that depend on
|
||||||
|
other values or packages.
|
||||||
*/
|
*/
|
||||||
literalExample = text: { _type = "literalExample"; inherit text; };
|
literalExpression = text:
|
||||||
|
if ! isString text then throw "literalExpression expects a string."
|
||||||
|
else { _type = "literalExpression"; inherit text; };
|
||||||
|
|
||||||
|
literalExample = lib.warn "literalExample is deprecated, use literalExpression instead, or use literalDocBook for a non-Nix description." literalExpression;
|
||||||
|
|
||||||
|
|
||||||
|
/* For use in the `defaultText` and `example` option attributes. Causes the
|
||||||
|
given DocBook text to be inserted verbatim in the documentation, for when
|
||||||
|
a `literalExpression` would be too hard to read.
|
||||||
|
*/
|
||||||
|
literalDocBook = text:
|
||||||
|
if ! isString text then throw "literalDocBook expects a string."
|
||||||
|
else { _type = "literalDocBook"; inherit text; };
|
||||||
|
|
||||||
# Helper functions.
|
# Helper functions.
|
||||||
|
|
||||||
|
|
1
third_party/nixpkgs/lib/systems/default.nix
vendored
1
third_party/nixpkgs/lib/systems/default.nix
vendored
|
@ -8,6 +8,7 @@ rec {
|
||||||
platforms = import ./platforms.nix { inherit lib; };
|
platforms = import ./platforms.nix { inherit lib; };
|
||||||
examples = import ./examples.nix { inherit lib; };
|
examples = import ./examples.nix { inherit lib; };
|
||||||
architectures = import ./architectures.nix { inherit lib; };
|
architectures = import ./architectures.nix { inherit lib; };
|
||||||
|
supported = import ./supported.nix { inherit lib; };
|
||||||
|
|
||||||
# Elaborate a `localSystem` or `crossSystem` so that it contains everything
|
# Elaborate a `localSystem` or `crossSystem` so that it contains everything
|
||||||
# necessary.
|
# necessary.
|
||||||
|
|
24
third_party/nixpkgs/lib/systems/supported.nix
vendored
Normal file
24
third_party/nixpkgs/lib/systems/supported.nix
vendored
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
# Supported systems according to RFC0046's definition.
|
||||||
|
#
|
||||||
|
# https://github.com/NixOS/rfcs/blob/master/rfcs/0046-platform-support-tiers.md
|
||||||
|
{ lib }:
|
||||||
|
rec {
|
||||||
|
# List of systems that are built by Hydra.
|
||||||
|
hydra = tier1 ++ tier2 ++ tier3;
|
||||||
|
|
||||||
|
tier1 = [
|
||||||
|
"x86_64-linux"
|
||||||
|
];
|
||||||
|
|
||||||
|
tier2 = [
|
||||||
|
"aarch64-linux"
|
||||||
|
"x86_64-darwin"
|
||||||
|
];
|
||||||
|
|
||||||
|
tier3 = [
|
||||||
|
"armv6l-linux"
|
||||||
|
"armv7l-linux"
|
||||||
|
"i686-linux"
|
||||||
|
"mipsel-linux"
|
||||||
|
];
|
||||||
|
}
|
4
third_party/nixpkgs/lib/tests/modules.sh
vendored
4
third_party/nixpkgs/lib/tests/modules.sh
vendored
|
@ -254,8 +254,10 @@ checkConfigOutput / config.value.path ./types-anything/equal-atoms.nix
|
||||||
checkConfigOutput null config.value.null ./types-anything/equal-atoms.nix
|
checkConfigOutput null config.value.null ./types-anything/equal-atoms.nix
|
||||||
checkConfigOutput 0.1 config.value.float ./types-anything/equal-atoms.nix
|
checkConfigOutput 0.1 config.value.float ./types-anything/equal-atoms.nix
|
||||||
# Functions can't be merged together
|
# Functions can't be merged together
|
||||||
checkConfigError "The option .* has conflicting definition values" config.value.multiple-lambdas ./types-anything/functions.nix
|
checkConfigError "The option .value.multiple-lambdas.<function body>. has conflicting option types" config.applied.multiple-lambdas ./types-anything/functions.nix
|
||||||
checkConfigOutput '<LAMBDA>' config.value.single-lambda ./types-anything/functions.nix
|
checkConfigOutput '<LAMBDA>' config.value.single-lambda ./types-anything/functions.nix
|
||||||
|
checkConfigOutput 'null' config.applied.merging-lambdas.x ./types-anything/functions.nix
|
||||||
|
checkConfigOutput 'null' config.applied.merging-lambdas.y ./types-anything/functions.nix
|
||||||
# Check that all mk* modifiers are applied
|
# Check that all mk* modifiers are applied
|
||||||
checkConfigError 'attribute .* not found' config.value.mkiffalse ./types-anything/mk-mods.nix
|
checkConfigError 'attribute .* not found' config.value.mkiffalse ./types-anything/mk-mods.nix
|
||||||
checkConfigOutput '{ }' config.value.mkiftrue ./types-anything/mk-mods.nix
|
checkConfigOutput '{ }' config.value.mkiftrue ./types-anything/mk-mods.nix
|
||||||
|
|
|
@ -1,16 +1,22 @@
|
||||||
{ lib, ... }: {
|
{ lib, config, ... }: {
|
||||||
|
|
||||||
options.value = lib.mkOption {
|
options.value = lib.mkOption {
|
||||||
type = lib.types.anything;
|
type = lib.types.anything;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
options.applied = lib.mkOption {
|
||||||
|
default = lib.mapAttrs (name: fun: fun null) config.value;
|
||||||
|
};
|
||||||
|
|
||||||
config = lib.mkMerge [
|
config = lib.mkMerge [
|
||||||
{
|
{
|
||||||
value.single-lambda = x: x;
|
value.single-lambda = x: x;
|
||||||
value.multiple-lambdas = x: x;
|
value.multiple-lambdas = x: { inherit x; };
|
||||||
|
value.merging-lambdas = x: { inherit x; };
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
value.multiple-lambdas = x: x;
|
value.multiple-lambdas = x: [ x ];
|
||||||
|
value.merging-lambdas = y: { inherit y; };
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
6
third_party/nixpkgs/lib/types.nix
vendored
6
third_party/nixpkgs/lib/types.nix
vendored
|
@ -192,6 +192,12 @@ rec {
|
||||||
else (listOf anything).merge;
|
else (listOf anything).merge;
|
||||||
# This is the type of packages, only accept a single definition
|
# This is the type of packages, only accept a single definition
|
||||||
stringCoercibleSet = mergeOneOption;
|
stringCoercibleSet = mergeOneOption;
|
||||||
|
lambda = loc: defs: arg: anything.merge
|
||||||
|
(loc ++ [ "<function body>" ])
|
||||||
|
(map (def: {
|
||||||
|
file = def.file;
|
||||||
|
value = def.value arg;
|
||||||
|
}) defs);
|
||||||
# Otherwise fall back to only allowing all equal definitions
|
# Otherwise fall back to only allowing all equal definitions
|
||||||
}.${commonType} or mergeEqualOption;
|
}.${commonType} or mergeEqualOption;
|
||||||
in mergeFunction loc defs;
|
in mergeFunction loc defs;
|
||||||
|
|
|
@ -3119,6 +3119,12 @@
|
||||||
githubId = 50854;
|
githubId = 50854;
|
||||||
name = "edef";
|
name = "edef";
|
||||||
};
|
};
|
||||||
|
edlimerkaj = {
|
||||||
|
name = "Edli Merkaj";
|
||||||
|
email = "edli.merkaj@identinet.io";
|
||||||
|
github = "edlimerkaj";
|
||||||
|
githubId = 71988351;
|
||||||
|
};
|
||||||
edibopp = {
|
edibopp = {
|
||||||
email = "eduard.bopp@aepsil0n.de";
|
email = "eduard.bopp@aepsil0n.de";
|
||||||
github = "edibopp";
|
github = "edibopp";
|
||||||
|
@ -8914,6 +8920,12 @@
|
||||||
githubId = 11365056;
|
githubId = 11365056;
|
||||||
name = "Kevin Liu";
|
name = "Kevin Liu";
|
||||||
};
|
};
|
||||||
|
pnmadelaine = {
|
||||||
|
name = "Paul-Nicolas Madelaine";
|
||||||
|
email = "pnm@pnm.tf";
|
||||||
|
github = "pnmadelaine";
|
||||||
|
githubId = 21977014;
|
||||||
|
};
|
||||||
pnotequalnp = {
|
pnotequalnp = {
|
||||||
email = "kevin@pnotequalnp.com";
|
email = "kevin@pnotequalnp.com";
|
||||||
github = "pnotequalnp";
|
github = "pnotequalnp";
|
||||||
|
@ -10288,6 +10300,12 @@
|
||||||
fingerprint = "ADF4 C13D 0E36 1240 BD01 9B51 D1DE 6D7F 6936 63A5";
|
fingerprint = "ADF4 C13D 0E36 1240 BD01 9B51 D1DE 6D7F 6936 63A5";
|
||||||
}];
|
}];
|
||||||
};
|
};
|
||||||
|
simarra = {
|
||||||
|
name = "simarra";
|
||||||
|
email = "loic.martel@protonmail.com";
|
||||||
|
github = "simarra";
|
||||||
|
githubId = 14372987;
|
||||||
|
};
|
||||||
simonchatts = {
|
simonchatts = {
|
||||||
email = "code@chatts.net";
|
email = "code@chatts.net";
|
||||||
github = "simonchatts";
|
github = "simonchatts";
|
||||||
|
|
|
@ -38,9 +38,19 @@ The function `mkOption` accepts the following arguments.
|
||||||
of the module will have to define the value of the option, otherwise
|
of the module will have to define the value of the option, otherwise
|
||||||
an error will be thrown.
|
an error will be thrown.
|
||||||
|
|
||||||
|
`defaultText`
|
||||||
|
|
||||||
|
: A textual representation of the default value to be rendered verbatim in
|
||||||
|
the manual. Useful if the default value is a complex expression or depends
|
||||||
|
on other values or packages.
|
||||||
|
Use `lib.literalExpression` for a Nix expression, `lib.literalDocBook` for
|
||||||
|
a plain English description in DocBook format.
|
||||||
|
|
||||||
`example`
|
`example`
|
||||||
|
|
||||||
: An example value that will be shown in the NixOS manual.
|
: An example value that will be shown in the NixOS manual.
|
||||||
|
You can use `lib.literalExpression` and `lib.literalDocBook` in the same way
|
||||||
|
as in `defaultText`.
|
||||||
|
|
||||||
`description`
|
`description`
|
||||||
|
|
||||||
|
|
|
@ -57,13 +57,31 @@ options = {
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
<varlistentry>
|
||||||
|
<term>
|
||||||
|
<literal>defaultText</literal>
|
||||||
|
</term>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
A textual representation of the default value to be rendered
|
||||||
|
verbatim in the manual. Useful if the default value is a
|
||||||
|
complex expression or depends on other values or packages. Use
|
||||||
|
<literal>lib.literalExpression</literal> for a Nix expression,
|
||||||
|
<literal>lib.literalDocBook</literal> for a plain English
|
||||||
|
description in DocBook format.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term>
|
<term>
|
||||||
<literal>example</literal>
|
<literal>example</literal>
|
||||||
</term>
|
</term>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
An example value that will be shown in the NixOS manual.
|
An example value that will be shown in the NixOS manual. You
|
||||||
|
can use <literal>lib.literalExpression</literal> and
|
||||||
|
<literal>lib.literalDocBook</literal> in the same way as in
|
||||||
|
<literal>defaultText</literal>.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
|
@ -54,7 +54,7 @@
|
||||||
<para>
|
<para>
|
||||||
<emphasis>Default:</emphasis>
|
<emphasis>Default:</emphasis>
|
||||||
<xsl:text> </xsl:text>
|
<xsl:text> </xsl:text>
|
||||||
<xsl:apply-templates select="attr[@name = 'default']" mode="top" />
|
<xsl:apply-templates select="attr[@name = 'default']/*" mode="top" />
|
||||||
</para>
|
</para>
|
||||||
</xsl:if>
|
</xsl:if>
|
||||||
|
|
||||||
|
@ -62,14 +62,7 @@
|
||||||
<para>
|
<para>
|
||||||
<emphasis>Example:</emphasis>
|
<emphasis>Example:</emphasis>
|
||||||
<xsl:text> </xsl:text>
|
<xsl:text> </xsl:text>
|
||||||
<xsl:choose>
|
<xsl:apply-templates select="attr[@name = 'example']/*" mode="top" />
|
||||||
<xsl:when test="attr[@name = 'example']/attrs[attr[@name = '_type' and string[@value = 'literalExample']]]">
|
|
||||||
<programlisting><xsl:value-of select="attr[@name = 'example']/attrs/attr[@name = 'text']/string/@value" /></programlisting>
|
|
||||||
</xsl:when>
|
|
||||||
<xsl:otherwise>
|
|
||||||
<xsl:apply-templates select="attr[@name = 'example']" mode="top" />
|
|
||||||
</xsl:otherwise>
|
|
||||||
</xsl:choose>
|
|
||||||
</para>
|
</para>
|
||||||
</xsl:if>
|
</xsl:if>
|
||||||
|
|
||||||
|
@ -107,20 +100,37 @@
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
<xsl:template match="*" mode="top">
|
<xsl:template match="attrs[attr[@name = '_type' and string[@value = 'literalExpression']]]" mode = "top">
|
||||||
<xsl:choose>
|
<xsl:choose>
|
||||||
<xsl:when test="string[contains(@value, '
')]">
|
<xsl:when test="contains(attr[@name = 'text']/string/@value, '
')">
|
||||||
<programlisting>
|
<programlisting><xsl:value-of select="attr[@name = 'text']/string/@value" /></programlisting>
|
||||||
<xsl:text>''
|
|
||||||
</xsl:text><xsl:value-of select='str:replace(string/@value, "${", "''${")' /><xsl:text>''</xsl:text></programlisting>
|
|
||||||
</xsl:when>
|
</xsl:when>
|
||||||
<xsl:otherwise>
|
<xsl:otherwise>
|
||||||
<literal><xsl:apply-templates /></literal>
|
<literal><xsl:value-of select="attr[@name = 'text']/string/@value" /></literal>
|
||||||
</xsl:otherwise>
|
</xsl:otherwise>
|
||||||
</xsl:choose>
|
</xsl:choose>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
|
<xsl:template match="attrs[attr[@name = '_type' and string[@value = 'literalDocBook']]]" mode = "top">
|
||||||
|
<xsl:value-of disable-output-escaping="yes" select="attr[@name = 'text']/string/@value" />
|
||||||
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
|
<xsl:template match="string[contains(@value, '
')]" mode="top">
|
||||||
|
<programlisting>
|
||||||
|
<xsl:text>''
</xsl:text>
|
||||||
|
<xsl:value-of select='str:replace(str:replace(@value, "''", "'''"), "${", "''${")' />
|
||||||
|
<xsl:text>''</xsl:text>
|
||||||
|
</programlisting>
|
||||||
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
|
<xsl:template match="*" mode="top">
|
||||||
|
<literal><xsl:apply-templates select="." /></literal>
|
||||||
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
<xsl:template match="null">
|
<xsl:template match="null">
|
||||||
<xsl:text>null</xsl:text>
|
<xsl:text>null</xsl:text>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
@ -129,10 +139,10 @@
|
||||||
<xsl:template match="string">
|
<xsl:template match="string">
|
||||||
<xsl:choose>
|
<xsl:choose>
|
||||||
<xsl:when test="(contains(@value, '"') or contains(@value, '\')) and not(contains(@value, '
'))">
|
<xsl:when test="(contains(@value, '"') or contains(@value, '\')) and not(contains(@value, '
'))">
|
||||||
<xsl:text>''</xsl:text><xsl:value-of select='str:replace(@value, "${", "''${")' /><xsl:text>''</xsl:text>
|
<xsl:text>''</xsl:text><xsl:value-of select='str:replace(str:replace(@value, "''", "'''"), "${", "''${")' /><xsl:text>''</xsl:text>
|
||||||
</xsl:when>
|
</xsl:when>
|
||||||
<xsl:otherwise>
|
<xsl:otherwise>
|
||||||
<xsl:text>"</xsl:text><xsl:value-of select="str:replace(str:replace(str:replace(str:replace(@value, '\', '\\'), '"', '\"'), '
', '\n'), '$', '\$')" /><xsl:text>"</xsl:text>
|
<xsl:text>"</xsl:text><xsl:value-of select="str:replace(str:replace(str:replace(str:replace(@value, '\', '\\'), '"', '\"'), '
', '\n'), '${', '\${')" /><xsl:text>"</xsl:text>
|
||||||
</xsl:otherwise>
|
</xsl:otherwise>
|
||||||
</xsl:choose>
|
</xsl:choose>
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
@ -163,7 +173,7 @@
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
||||||
<xsl:template match="attrs[attr[@name = '_type' and string[@value = 'literalExample']]]">
|
<xsl:template match="attrs[attr[@name = '_type' and string[@value = 'literalExpression']]]">
|
||||||
<xsl:value-of select="attr[@name = 'text']/string/@value" />
|
<xsl:value-of select="attr[@name = 'text']/string/@value" />
|
||||||
</xsl:template>
|
</xsl:template>
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
contents = mkOption {
|
contents = mkOption {
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[ { source = pkgs.memtest86 + "/memtest.bin";
|
[ { source = pkgs.memtest86 + "/memtest.bin";
|
||||||
target = "boot/memtest.bin";
|
target = "boot/memtest.bin";
|
||||||
}
|
}
|
||||||
|
|
|
@ -61,7 +61,7 @@ in
|
||||||
fonts = mkOption {
|
fonts = mkOption {
|
||||||
type = types.listOf types.path;
|
type = types.listOf types.path;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ pkgs.dejavu_fonts ]";
|
example = literalExpression "[ pkgs.dejavu_fonts ]";
|
||||||
description = "List of primary font paths.";
|
description = "List of primary font paths.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,7 @@ with lib;
|
||||||
allLocales = any (x: x == "all") config.i18n.supportedLocales;
|
allLocales = any (x: x == "all") config.i18n.supportedLocales;
|
||||||
locales = config.i18n.supportedLocales;
|
locales = config.i18n.supportedLocales;
|
||||||
};
|
};
|
||||||
example = literalExample "pkgs.glibcLocales";
|
example = literalExpression "pkgs.glibcLocales";
|
||||||
description = ''
|
description = ''
|
||||||
Customized pkg.glibcLocales package.
|
Customized pkg.glibcLocales package.
|
||||||
|
|
||||||
|
|
|
@ -83,8 +83,8 @@ in {
|
||||||
kerberos = mkOption {
|
kerberos = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.krb5Full;
|
default = pkgs.krb5Full;
|
||||||
defaultText = "pkgs.krb5Full";
|
defaultText = literalExpression "pkgs.krb5Full";
|
||||||
example = literalExample "pkgs.heimdal";
|
example = literalExpression "pkgs.heimdal";
|
||||||
description = ''
|
description = ''
|
||||||
The Kerberos implementation that will be present in
|
The Kerberos implementation that will be present in
|
||||||
<literal>environment.systemPackages</literal> after enabling this
|
<literal>environment.systemPackages</literal> after enabling this
|
||||||
|
@ -96,7 +96,7 @@ in {
|
||||||
type = with types; either attrs lines;
|
type = with types; either attrs lines;
|
||||||
default = {};
|
default = {};
|
||||||
apply = attrs: filterEmbeddedMetadata attrs;
|
apply = attrs: filterEmbeddedMetadata attrs;
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
default_realm = "ATHENA.MIT.EDU";
|
default_realm = "ATHENA.MIT.EDU";
|
||||||
};
|
};
|
||||||
|
@ -109,7 +109,7 @@ in {
|
||||||
realms = mkOption {
|
realms = mkOption {
|
||||||
type = with types; either attrs lines;
|
type = with types; either attrs lines;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"ATHENA.MIT.EDU" = {
|
"ATHENA.MIT.EDU" = {
|
||||||
admin_server = "athena.mit.edu";
|
admin_server = "athena.mit.edu";
|
||||||
|
@ -127,7 +127,7 @@ in {
|
||||||
domain_realm = mkOption {
|
domain_realm = mkOption {
|
||||||
type = with types; either attrs lines;
|
type = with types; either attrs lines;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"example.com" = "EXAMPLE.COM";
|
"example.com" = "EXAMPLE.COM";
|
||||||
".example.com" = "EXAMPLE.COM";
|
".example.com" = "EXAMPLE.COM";
|
||||||
|
@ -142,7 +142,7 @@ in {
|
||||||
capaths = mkOption {
|
capaths = mkOption {
|
||||||
type = with types; either attrs lines;
|
type = with types; either attrs lines;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"ATHENA.MIT.EDU" = {
|
"ATHENA.MIT.EDU" = {
|
||||||
"EXAMPLE.COM" = ".";
|
"EXAMPLE.COM" = ".";
|
||||||
|
@ -161,7 +161,7 @@ in {
|
||||||
appdefaults = mkOption {
|
appdefaults = mkOption {
|
||||||
type = with types; either attrs lines;
|
type = with types; either attrs lines;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
pam = {
|
pam = {
|
||||||
debug = false;
|
debug = false;
|
||||||
|
@ -182,7 +182,7 @@ in {
|
||||||
plugins = mkOption {
|
plugins = mkOption {
|
||||||
type = with types; either attrs lines;
|
type = with types; either attrs lines;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
ccselect = {
|
ccselect = {
|
||||||
disable = "k5identity";
|
disable = "k5identity";
|
||||||
|
|
|
@ -21,7 +21,7 @@ in
|
||||||
|
|
||||||
networking.hosts = lib.mkOption {
|
networking.hosts = lib.mkOption {
|
||||||
type = types.attrsOf (types.listOf types.str);
|
type = types.attrsOf (types.listOf types.str);
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"127.0.0.1" = [ "foo.bar.baz" ];
|
"127.0.0.1" = [ "foo.bar.baz" ];
|
||||||
"192.168.0.2" = [ "fileserver.local" "nameserver.local" ];
|
"192.168.0.2" = [ "fileserver.local" "nameserver.local" ];
|
||||||
|
@ -34,8 +34,8 @@ in
|
||||||
|
|
||||||
networking.hostFiles = lib.mkOption {
|
networking.hostFiles = lib.mkOption {
|
||||||
type = types.listOf types.path;
|
type = types.listOf types.path;
|
||||||
defaultText = lib.literalExample "Hosts from `networking.hosts` and `networking.extraHosts`";
|
defaultText = literalDocBook "Hosts from <option>networking.hosts</option> and <option>networking.extraHosts</option>";
|
||||||
example = lib.literalExample ''[ "''${pkgs.my-blocklist-package}/share/my-blocklist/hosts" ]'';
|
example = literalExpression ''[ "''${pkgs.my-blocklist-package}/share/my-blocklist/hosts" ]'';
|
||||||
description = ''
|
description = ''
|
||||||
Files that should be concatenated together to form <filename>/etc/hosts</filename>.
|
Files that should be concatenated together to form <filename>/etc/hosts</filename>.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -35,7 +35,7 @@ in
|
||||||
powerUpCommands = mkOption {
|
powerUpCommands = mkOption {
|
||||||
type = types.lines;
|
type = types.lines;
|
||||||
default = "";
|
default = "";
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
"''${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda"
|
"''${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda"
|
||||||
'';
|
'';
|
||||||
description =
|
description =
|
||||||
|
@ -49,7 +49,7 @@ in
|
||||||
powerDownCommands = mkOption {
|
powerDownCommands = mkOption {
|
||||||
type = types.lines;
|
type = types.lines;
|
||||||
default = "";
|
default = "";
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
"''${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda"
|
"''${pkgs.hdparm}/sbin/hdparm -B 255 /dev/sda"
|
||||||
'';
|
'';
|
||||||
description =
|
description =
|
||||||
|
|
|
@ -149,8 +149,8 @@ in {
|
||||||
default = if config.services.jack.jackd.enable
|
default = if config.services.jack.jackd.enable
|
||||||
then pkgs.pulseaudioFull
|
then pkgs.pulseaudioFull
|
||||||
else pkgs.pulseaudio;
|
else pkgs.pulseaudio;
|
||||||
defaultText = "pkgs.pulseaudio";
|
defaultText = literalExpression "pkgs.pulseaudio";
|
||||||
example = literalExample "pkgs.pulseaudioFull";
|
example = literalExpression "pkgs.pulseaudioFull";
|
||||||
description = ''
|
description = ''
|
||||||
The PulseAudio derivation to use. This can be used to enable
|
The PulseAudio derivation to use. This can be used to enable
|
||||||
features (such as JACK support, Bluetooth) via the
|
features (such as JACK support, Bluetooth) via the
|
||||||
|
@ -161,7 +161,7 @@ in {
|
||||||
extraModules = mkOption {
|
extraModules = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ pkgs.pulseaudio-modules-bt ]";
|
example = literalExpression "[ pkgs.pulseaudio-modules-bt ]";
|
||||||
description = ''
|
description = ''
|
||||||
Extra pulseaudio modules to use. This is intended for out-of-tree
|
Extra pulseaudio modules to use. This is intended for out-of-tree
|
||||||
pulseaudio modules like extra bluetooth codecs.
|
pulseaudio modules like extra bluetooth codecs.
|
||||||
|
@ -184,7 +184,7 @@ in {
|
||||||
type = types.attrsOf types.unspecified;
|
type = types.attrsOf types.unspecified;
|
||||||
default = {};
|
default = {};
|
||||||
description = "Config of the pulse daemon. See <literal>man pulse-daemon.conf</literal>.";
|
description = "Config of the pulse daemon. See <literal>man pulse-daemon.conf</literal>.";
|
||||||
example = literalExample ''{ realtime-scheduling = "yes"; }'';
|
example = literalExpression ''{ realtime-scheduling = "yes"; }'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -204,7 +204,7 @@ in {
|
||||||
allowedIpRanges = mkOption {
|
allowedIpRanges = mkOption {
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample ''[ "127.0.0.1" "192.168.1.0/24" ]'';
|
example = literalExpression ''[ "127.0.0.1" "192.168.1.0/24" ]'';
|
||||||
description = ''
|
description = ''
|
||||||
A list of IP subnets that are allowed to stream to the server.
|
A list of IP subnets that are allowed to stream to the server.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -136,10 +136,8 @@ in
|
||||||
|
|
||||||
environment.binsh = mkOption {
|
environment.binsh = mkOption {
|
||||||
default = "${config.system.build.binsh}/bin/sh";
|
default = "${config.system.build.binsh}/bin/sh";
|
||||||
defaultText = "\${config.system.build.binsh}/bin/sh";
|
defaultText = literalExpression ''"''${config.system.build.binsh}/bin/sh"'';
|
||||||
example = literalExample ''
|
example = literalExpression ''"''${pkgs.dash}/bin/dash"'';
|
||||||
"''${pkgs.dash}/bin/dash"
|
|
||||||
'';
|
|
||||||
type = types.path;
|
type = types.path;
|
||||||
visible = false;
|
visible = false;
|
||||||
description = ''
|
description = ''
|
||||||
|
@ -152,7 +150,7 @@ in
|
||||||
|
|
||||||
environment.shells = mkOption {
|
environment.shells = mkOption {
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ pkgs.bashInteractive pkgs.zsh ]";
|
example = literalExpression "[ pkgs.bashInteractive pkgs.zsh ]";
|
||||||
description = ''
|
description = ''
|
||||||
A list of permissible login shells for user accounts.
|
A list of permissible login shells for user accounts.
|
||||||
No need to mention <literal>/bin/sh</literal>
|
No need to mention <literal>/bin/sh</literal>
|
||||||
|
|
|
@ -22,7 +22,7 @@ in
|
||||||
|
|
||||||
boot.kernel.sysctl = mkOption {
|
boot.kernel.sysctl = mkOption {
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{ "net.ipv4.tcp_syncookies" = false; "vm.swappiness" = 60; }
|
{ "net.ipv4.tcp_syncookies" = false; "vm.swappiness" = 60; }
|
||||||
'';
|
'';
|
||||||
type = types.attrsOf sysctlOption;
|
type = types.attrsOf sysctlOption;
|
||||||
|
|
|
@ -58,7 +58,7 @@ in
|
||||||
systemPackages = mkOption {
|
systemPackages = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ pkgs.firefox pkgs.thunderbird ]";
|
example = literalExpression "[ pkgs.firefox pkgs.thunderbird ]";
|
||||||
description = ''
|
description = ''
|
||||||
The set of packages that appear in
|
The set of packages that appear in
|
||||||
/run/current-system/sw. These packages are
|
/run/current-system/sw. These packages are
|
||||||
|
@ -73,9 +73,9 @@ in
|
||||||
defaultPackages = mkOption {
|
defaultPackages = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = defaultPackages;
|
default = defaultPackages;
|
||||||
example = literalExample "[]";
|
example = [];
|
||||||
description = ''
|
description = ''
|
||||||
Set of default packages that aren't strictly neccessary
|
Set of default packages that aren't strictly necessary
|
||||||
for a running system, entries can be removed for a more
|
for a running system, entries can be removed for a more
|
||||||
minimal NixOS installation.
|
minimal NixOS installation.
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@ in {
|
||||||
environment.unixODBCDrivers = mkOption {
|
environment.unixODBCDrivers = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "with pkgs.unixODBCDrivers; [ sqlite psql ]";
|
example = literalExpression "with pkgs.unixODBCDrivers; [ sqlite psql ]";
|
||||||
description = ''
|
description = ''
|
||||||
Specifies Unix ODBC drivers to be registered in
|
Specifies Unix ODBC drivers to be registered in
|
||||||
<filename>/etc/odbcinst.ini</filename>. You may also want to
|
<filename>/etc/odbcinst.ini</filename>. You may also want to
|
||||||
|
|
|
@ -165,8 +165,8 @@ let
|
||||||
shell = mkOption {
|
shell = mkOption {
|
||||||
type = types.nullOr (types.either types.shellPackage (passwdEntry types.path));
|
type = types.nullOr (types.either types.shellPackage (passwdEntry types.path));
|
||||||
default = pkgs.shadow;
|
default = pkgs.shadow;
|
||||||
defaultText = "pkgs.shadow";
|
defaultText = literalExpression "pkgs.shadow";
|
||||||
example = literalExample "pkgs.bashInteractive";
|
example = literalExpression "pkgs.bashInteractive";
|
||||||
description = ''
|
description = ''
|
||||||
The path to the user's shell. Can use shell derivations,
|
The path to the user's shell. Can use shell derivations,
|
||||||
like <literal>pkgs.bashInteractive</literal>. Don’t
|
like <literal>pkgs.bashInteractive</literal>. Don’t
|
||||||
|
@ -291,7 +291,7 @@ let
|
||||||
packages = mkOption {
|
packages = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ pkgs.firefox pkgs.thunderbird ]";
|
example = literalExpression "[ pkgs.firefox pkgs.thunderbird ]";
|
||||||
description = ''
|
description = ''
|
||||||
The set of packages that should be made available to the user.
|
The set of packages that should be made available to the user.
|
||||||
This is in contrast to <option>environment.systemPackages</option>,
|
This is in contrast to <option>environment.systemPackages</option>,
|
||||||
|
|
|
@ -37,7 +37,7 @@ in
|
||||||
default = { };
|
default = { };
|
||||||
|
|
||||||
# Example taken from the manpage
|
# Example taken from the manpage
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
screencast = {
|
screencast = {
|
||||||
output_name = "HDMI-A-1";
|
output_name = "HDMI-A-1";
|
||||||
|
|
|
@ -27,7 +27,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.ckb-next;
|
default = pkgs.ckb-next;
|
||||||
defaultText = "pkgs.ckb-next";
|
defaultText = literalExpression "pkgs.ckb-next";
|
||||||
description = ''
|
description = ''
|
||||||
The package implementing the Corsair keyboard/mouse driver.
|
The package implementing the Corsair keyboard/mouse driver.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -21,7 +21,7 @@ let
|
||||||
each .dtb file matching "compatible" of the overlay.
|
each .dtb file matching "compatible" of the overlay.
|
||||||
'';
|
'';
|
||||||
default = null;
|
default = null;
|
||||||
example = literalExample "./dts/overlays.dts";
|
example = literalExpression "./dts/overlays.dts";
|
||||||
};
|
};
|
||||||
|
|
||||||
dtsText = mkOption {
|
dtsText = mkOption {
|
||||||
|
@ -31,7 +31,7 @@ let
|
||||||
Literal DTS contents, overlay is applied to
|
Literal DTS contents, overlay is applied to
|
||||||
each .dtb file matching "compatible" of the overlay.
|
each .dtb file matching "compatible" of the overlay.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = ''
|
||||||
/dts-v1/;
|
/dts-v1/;
|
||||||
/plugin/;
|
/plugin/;
|
||||||
/ {
|
/ {
|
||||||
|
@ -125,8 +125,8 @@ in
|
||||||
|
|
||||||
kernelPackage = mkOption {
|
kernelPackage = mkOption {
|
||||||
default = config.boot.kernelPackages.kernel;
|
default = config.boot.kernelPackages.kernel;
|
||||||
defaultText = "config.boot.kernelPackages.kernel";
|
defaultText = literalExpression "config.boot.kernelPackages.kernel";
|
||||||
example = literalExample "pkgs.linux_latest";
|
example = literalExpression "pkgs.linux_latest";
|
||||||
type = types.path;
|
type = types.path;
|
||||||
description = ''
|
description = ''
|
||||||
Kernel package containing the base device-tree (.dtb) to boot. Uses
|
Kernel package containing the base device-tree (.dtb) to boot. Uses
|
||||||
|
@ -156,7 +156,7 @@ in
|
||||||
|
|
||||||
overlays = mkOption {
|
overlays = mkOption {
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[
|
[
|
||||||
{ name = "pps"; dtsFile = ./dts/pps.dts; }
|
{ name = "pps"; dtsFile = ./dts/pps.dts; }
|
||||||
{ name = "spi";
|
{ name = "spi";
|
||||||
|
|
|
@ -19,7 +19,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.digitalbitbox;
|
default = pkgs.digitalbitbox;
|
||||||
defaultText = "pkgs.digitalbitbox";
|
defaultText = literalExpression "pkgs.digitalbitbox";
|
||||||
description = "The Digital Bitbox package to use. This can be used to install a package with udev rules that differ from the defaults.";
|
description = "The Digital Bitbox package to use. This can be used to install a package with udev rules that differ from the defaults.";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -89,7 +89,7 @@ in
|
||||||
extraPackages = mkOption {
|
extraPackages = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "with pkgs; [ vaapiIntel libvdpau-va-gl vaapiVdpau intel-ocl ]";
|
example = literalExpression "with pkgs; [ vaapiIntel libvdpau-va-gl vaapiVdpau intel-ocl ]";
|
||||||
description = ''
|
description = ''
|
||||||
Additional packages to add to OpenGL drivers. This can be used
|
Additional packages to add to OpenGL drivers. This can be used
|
||||||
to add OpenCL drivers, VA-API/VDPAU drivers etc.
|
to add OpenCL drivers, VA-API/VDPAU drivers etc.
|
||||||
|
@ -99,7 +99,7 @@ in
|
||||||
extraPackages32 = mkOption {
|
extraPackages32 = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "with pkgs.pkgsi686Linux; [ vaapiIntel libvdpau-va-gl vaapiVdpau ]";
|
example = literalExpression "with pkgs.pkgsi686Linux; [ vaapiIntel libvdpau-va-gl vaapiVdpau ]";
|
||||||
description = ''
|
description = ''
|
||||||
Additional packages to add to 32-bit OpenGL drivers on
|
Additional packages to add to 32-bit OpenGL drivers on
|
||||||
64-bit systems. Used when <option>driSupport32Bit</option> is
|
64-bit systems. Used when <option>driSupport32Bit</option> is
|
||||||
|
|
|
@ -29,7 +29,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.opentabletdriver;
|
default = pkgs.opentabletdriver;
|
||||||
defaultText = "pkgs.opentabletdriver";
|
defaultText = literalExpression "pkgs.opentabletdriver";
|
||||||
description = ''
|
description = ''
|
||||||
OpenTabletDriver derivation to use.
|
OpenTabletDriver derivation to use.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -72,10 +72,10 @@ in {
|
||||||
};
|
};
|
||||||
deviceUri = mkOption {
|
deviceUri = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
example = [
|
example = literalExpression ''
|
||||||
"ipp://printserver.local/printers/BrotherHL_Workroom"
|
"ipp://printserver.local/printers/BrotherHL_Workroom"
|
||||||
"usb://HP/DESKJET%20940C?serial=CN16E6C364BH"
|
"usb://HP/DESKJET%20940C?serial=CN16E6C364BH"
|
||||||
];
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
How to reach the printer.
|
How to reach the printer.
|
||||||
<command>lpinfo -v</command> shows a list of supported device URIs and schemes.
|
<command>lpinfo -v</command> shows a list of supported device URIs and schemes.
|
||||||
|
@ -83,8 +83,8 @@ in {
|
||||||
};
|
};
|
||||||
model = mkOption {
|
model = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
gutenprint.''${lib.versions.majorMinor (lib.getVersion pkgs.gutenprint)}://brother-hl-5140/expert
|
"gutenprint.''${lib.versions.majorMinor (lib.getVersion pkgs.gutenprint)}://brother-hl-5140/expert"
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
Location of the ppd driver file for the printer.
|
Location of the ppd driver file for the printer.
|
||||||
|
|
|
@ -39,7 +39,7 @@ in
|
||||||
enable = mkEnableOption "SATA drive timeouts";
|
enable = mkEnableOption "SATA drive timeouts";
|
||||||
|
|
||||||
deciSeconds = mkOption {
|
deciSeconds = mkOption {
|
||||||
example = "70";
|
example = 70;
|
||||||
type = types.int;
|
type = types.int;
|
||||||
description = ''
|
description = ''
|
||||||
Set SCT Error Recovery Control timeout in deciseconds for use in RAID configurations.
|
Set SCT Error Recovery Control timeout in deciseconds for use in RAID configurations.
|
||||||
|
|
|
@ -165,11 +165,11 @@ in
|
||||||
hardware.nvidia.package = lib.mkOption {
|
hardware.nvidia.package = lib.mkOption {
|
||||||
type = lib.types.package;
|
type = lib.types.package;
|
||||||
default = config.boot.kernelPackages.nvidiaPackages.stable;
|
default = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||||
defaultText = "config.boot.kernelPackages.nvidiaPackages.stable";
|
defaultText = literalExpression "config.boot.kernelPackages.nvidiaPackages.stable";
|
||||||
description = ''
|
description = ''
|
||||||
The NVIDIA X11 derivation to use.
|
The NVIDIA X11 derivation to use.
|
||||||
'';
|
'';
|
||||||
example = "config.boot.kernelPackages.nvidiaPackages.legacy_340";
|
example = literalExpression "config.boot.kernelPackages.nvidiaPackages.legacy_340";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -33,7 +33,7 @@ in
|
||||||
|
|
||||||
packages = mkOption {
|
packages = mkOption {
|
||||||
type = types.listOf types.path;
|
type = types.listOf types.path;
|
||||||
example = literalExample "[ pkgs.tiscamera ]";
|
example = literalExpression "[ pkgs.tiscamera ]";
|
||||||
description = ''
|
description = ''
|
||||||
List of packages containing <command>uvcvideo</command> dynamic controls
|
List of packages containing <command>uvcvideo</command> dynamic controls
|
||||||
rules. All files found in
|
rules. All files found in
|
||||||
|
|
|
@ -17,7 +17,7 @@ in
|
||||||
engines = mkOption {
|
engines = mkOption {
|
||||||
type = with types; listOf fcitxEngine;
|
type = with types; listOf fcitxEngine;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "with pkgs.fcitx-engines; [ mozc hangul ]";
|
example = literalExpression "with pkgs.fcitx-engines; [ mozc hangul ]";
|
||||||
description =
|
description =
|
||||||
let
|
let
|
||||||
enginesDrv = filterAttrs (const isDerivation) pkgs.fcitx-engines;
|
enginesDrv = filterAttrs (const isDerivation) pkgs.fcitx-engines;
|
||||||
|
|
|
@ -12,7 +12,7 @@ in {
|
||||||
addons = mkOption {
|
addons = mkOption {
|
||||||
type = with types; listOf package;
|
type = with types; listOf package;
|
||||||
default = [];
|
default = [];
|
||||||
example = with pkgs; [ fcitx5-rime ];
|
example = literalExpression "with pkgs; [ fcitx5-rime ]";
|
||||||
description = ''
|
description = ''
|
||||||
Enabled Fcitx5 addons.
|
Enabled Fcitx5 addons.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -36,7 +36,7 @@ in
|
||||||
engines = mkOption {
|
engines = mkOption {
|
||||||
type = with types; listOf ibusEngine;
|
type = with types; listOf ibusEngine;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "with pkgs.ibus-engines; [ mozc hangul ]";
|
example = literalExpression "with pkgs.ibus-engines; [ mozc hangul ]";
|
||||||
description =
|
description =
|
||||||
let
|
let
|
||||||
enginesDrv = filterAttrs (const isDerivation) pkgs.ibus-engines;
|
enginesDrv = filterAttrs (const isDerivation) pkgs.ibus-engines;
|
||||||
|
@ -48,7 +48,7 @@ in
|
||||||
panel = mkOption {
|
panel = mkOption {
|
||||||
type = with types; nullOr path;
|
type = with types; nullOr path;
|
||||||
default = null;
|
default = null;
|
||||||
example = literalExample "''${pkgs.plasma5Packages.plasma-desktop}/lib/libexec/kimpanel-ibus-panel";
|
example = literalExpression ''"''${pkgs.plasma5Packages.plasma-desktop}/lib/libexec/kimpanel-ibus-panel"'';
|
||||||
description = "Replace the IBus panel with another panel.";
|
description = "Replace the IBus panel with another panel.";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -10,7 +10,7 @@ in
|
||||||
config = mkOption {
|
config = mkOption {
|
||||||
type = yamlFormat.type;
|
type = yamlFormat.type;
|
||||||
default = { };
|
default = { };
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
daemon = {
|
daemon = {
|
||||||
modules = ["Xim" "Indicator"];
|
modules = ["Xim" "Indicator"];
|
||||||
|
|
|
@ -528,7 +528,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
isoImage.contents = mkOption {
|
isoImage.contents = mkOption {
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[ { source = pkgs.memtest86 + "/memtest.bin";
|
[ { source = pkgs.memtest86 + "/memtest.bin";
|
||||||
target = "boot/memtest.bin";
|
target = "boot/memtest.bin";
|
||||||
}
|
}
|
||||||
|
@ -541,7 +541,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
isoImage.storeContents = mkOption {
|
isoImage.storeContents = mkOption {
|
||||||
example = literalExample "[ pkgs.stdenv ]";
|
example = literalExpression "[ pkgs.stdenv ]";
|
||||||
description = ''
|
description = ''
|
||||||
This option lists additional derivations to be included in the
|
This option lists additional derivations to be included in the
|
||||||
Nix store in the generated ISO image.
|
Nix store in the generated ISO image.
|
||||||
|
|
|
@ -15,7 +15,7 @@ in
|
||||||
{
|
{
|
||||||
options = {
|
options = {
|
||||||
tarball.contents = mkOption {
|
tarball.contents = mkOption {
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[ { source = pkgs.memtest86 + "/memtest.bin";
|
[ { source = pkgs.memtest86 + "/memtest.bin";
|
||||||
target = "boot/memtest.bin";
|
target = "boot/memtest.bin";
|
||||||
}
|
}
|
||||||
|
@ -28,7 +28,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
tarball.storeContents = mkOption {
|
tarball.storeContents = mkOption {
|
||||||
example = literalExample "[ pkgs.stdenv ]";
|
example = literalExpression "[ pkgs.stdenv ]";
|
||||||
description = ''
|
description = ''
|
||||||
This option lists additional derivations to be included in the
|
This option lists additional derivations to be included in the
|
||||||
Nix store in the generated ISO image.
|
Nix store in the generated ISO image.
|
||||||
|
|
|
@ -9,7 +9,7 @@ with lib;
|
||||||
options = {
|
options = {
|
||||||
|
|
||||||
netboot.storeContents = mkOption {
|
netboot.storeContents = mkOption {
|
||||||
example = literalExample "[ pkgs.stdenv ]";
|
example = literalExpression "[ pkgs.stdenv ]";
|
||||||
description = ''
|
description = ''
|
||||||
This option lists additional derivations to be included in the
|
This option lists additional derivations to be included in the
|
||||||
Nix store in the generated netboot image.
|
Nix store in the generated netboot image.
|
||||||
|
|
|
@ -49,7 +49,7 @@ in
|
||||||
|
|
||||||
storePaths = mkOption {
|
storePaths = mkOption {
|
||||||
type = with types; listOf package;
|
type = with types; listOf package;
|
||||||
example = literalExample "[ pkgs.stdenv ]";
|
example = literalExpression "[ pkgs.stdenv ]";
|
||||||
description = ''
|
description = ''
|
||||||
Derivations to be included in the Nix store in the generated SD image.
|
Derivations to be included in the Nix store in the generated SD image.
|
||||||
'';
|
'';
|
||||||
|
@ -107,7 +107,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
populateFirmwareCommands = mkOption {
|
populateFirmwareCommands = mkOption {
|
||||||
example = literalExample "'' cp \${pkgs.myBootLoader}/u-boot.bin firmware/ ''";
|
example = literalExpression "'' cp \${pkgs.myBootLoader}/u-boot.bin firmware/ ''";
|
||||||
description = ''
|
description = ''
|
||||||
Shell commands to populate the ./firmware directory.
|
Shell commands to populate the ./firmware directory.
|
||||||
All files in that directory are copied to the
|
All files in that directory are copied to the
|
||||||
|
@ -116,7 +116,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
populateRootCommands = mkOption {
|
populateRootCommands = mkOption {
|
||||||
example = literalExample "''\${config.boot.loader.generic-extlinux-compatible.populateCmd} -c \${config.system.build.toplevel} -d ./files/boot''";
|
example = literalExpression "''\${config.boot.loader.generic-extlinux-compatible.populateCmd} -c \${config.system.build.toplevel} -d ./files/boot''";
|
||||||
description = ''
|
description = ''
|
||||||
Shell commands to populate the ./files directory.
|
Shell commands to populate the ./files directory.
|
||||||
All files in that directory are copied to the
|
All files in that directory are copied to the
|
||||||
|
@ -126,7 +126,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
postBuildCommands = mkOption {
|
postBuildCommands = mkOption {
|
||||||
example = literalExample "'' dd if=\${pkgs.myBootLoader}/SPL of=$img bs=1024 seek=1 conv=notrunc ''";
|
example = literalExpression "'' dd if=\${pkgs.myBootLoader}/SPL of=$img bs=1024 seek=1 conv=notrunc ''";
|
||||||
default = "";
|
default = "";
|
||||||
description = ''
|
description = ''
|
||||||
Shell commands to run after the image is built.
|
Shell commands to run after the image is built.
|
||||||
|
|
|
@ -133,7 +133,7 @@ in
|
||||||
extraOutputsToInstall = ["man"];
|
extraOutputsToInstall = ["man"];
|
||||||
ignoreCollisions = true;
|
ignoreCollisions = true;
|
||||||
};
|
};
|
||||||
defaultText = "all man pages in config.environment.systemPackages";
|
defaultText = literalDocBook "all man pages in <option>config.environment.systemPackages</option>";
|
||||||
description = ''
|
description = ''
|
||||||
The manual pages to generate caches for if <option>generateCaches</option>
|
The manual pages to generate caches for if <option>generateCaches</option>
|
||||||
is enabled. Must be a path to a directory with man pages under
|
is enabled. Must be a path to a directory with man pages under
|
||||||
|
@ -211,7 +211,7 @@ in
|
||||||
Which extra NixOS module paths the generated NixOS's documentation should strip
|
Which extra NixOS module paths the generated NixOS's documentation should strip
|
||||||
from options.
|
from options.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
# e.g. with options from modules in ''${pkgs.customModules}/nix:
|
# e.g. with options from modules in ''${pkgs.customModules}/nix:
|
||||||
[ pkgs.customModules ]
|
[ pkgs.customModules ]
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -48,7 +48,7 @@ in
|
||||||
#disk = 6; # unused
|
#disk = 6; # unused
|
||||||
#vsftpd = 7; # dynamically allocated ass of 2021-09-14
|
#vsftpd = 7; # dynamically allocated ass of 2021-09-14
|
||||||
ftp = 8;
|
ftp = 8;
|
||||||
bitlbee = 9;
|
# bitlbee = 9; # removed 2021-10-05 #139765
|
||||||
#avahi = 10; # removed 2019-05-22
|
#avahi = 10; # removed 2019-05-22
|
||||||
nagios = 11;
|
nagios = 11;
|
||||||
atd = 12;
|
atd = 12;
|
||||||
|
@ -368,7 +368,7 @@ in
|
||||||
disk = 6;
|
disk = 6;
|
||||||
#vsftpd = 7; # dynamically allocated as of 2021-09-14
|
#vsftpd = 7; # dynamically allocated as of 2021-09-14
|
||||||
ftp = 8;
|
ftp = 8;
|
||||||
bitlbee = 9;
|
# bitlbee = 9; # removed 2021-10-05 #139765
|
||||||
#avahi = 10; # removed 2019-05-22
|
#avahi = 10; # removed 2019-05-22
|
||||||
#nagios = 11; # unused
|
#nagios = 11; # unused
|
||||||
atd = 12;
|
atd = 12;
|
||||||
|
|
|
@ -25,8 +25,8 @@ in {
|
||||||
locate = mkOption {
|
locate = mkOption {
|
||||||
type = package;
|
type = package;
|
||||||
default = pkgs.findutils;
|
default = pkgs.findutils;
|
||||||
defaultText = "pkgs.findutils";
|
defaultText = literalExpression "pkgs.findutils";
|
||||||
example = "pkgs.mlocate";
|
example = literalExpression "pkgs.mlocate";
|
||||||
description = ''
|
description = ''
|
||||||
The locate implementation to use
|
The locate implementation to use
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -67,13 +67,13 @@ in
|
||||||
options.nixpkgs = {
|
options.nixpkgs = {
|
||||||
|
|
||||||
pkgs = mkOption {
|
pkgs = mkOption {
|
||||||
defaultText = literalExample
|
defaultText = literalExpression ''
|
||||||
''import "''${nixos}/.." {
|
import "''${nixos}/.." {
|
||||||
inherit (cfg) config overlays localSystem crossSystem;
|
inherit (cfg) config overlays localSystem crossSystem;
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
type = pkgsType;
|
type = pkgsType;
|
||||||
example = literalExample "import <nixpkgs> {}";
|
example = literalExpression "import <nixpkgs> {}";
|
||||||
description = ''
|
description = ''
|
||||||
If set, the pkgs argument to all NixOS modules is the value of
|
If set, the pkgs argument to all NixOS modules is the value of
|
||||||
this option, extended with <code>nixpkgs.overlays</code>, if
|
this option, extended with <code>nixpkgs.overlays</code>, if
|
||||||
|
@ -109,7 +109,7 @@ in
|
||||||
|
|
||||||
config = mkOption {
|
config = mkOption {
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample
|
example = literalExpression
|
||||||
''
|
''
|
||||||
{ allowBroken = true; allowUnfree = true; }
|
{ allowBroken = true; allowUnfree = true; }
|
||||||
'';
|
'';
|
||||||
|
@ -125,7 +125,7 @@ in
|
||||||
|
|
||||||
overlays = mkOption {
|
overlays = mkOption {
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample
|
example = literalExpression
|
||||||
''
|
''
|
||||||
[
|
[
|
||||||
(self: super: {
|
(self: super: {
|
||||||
|
@ -158,7 +158,7 @@ in
|
||||||
# Make sure that the final value has all fields for sake of other modules
|
# Make sure that the final value has all fields for sake of other modules
|
||||||
# referring to this. TODO make `lib.systems` itself use the module system.
|
# referring to this. TODO make `lib.systems` itself use the module system.
|
||||||
apply = lib.systems.elaborate;
|
apply = lib.systems.elaborate;
|
||||||
defaultText = literalExample
|
defaultText = literalExpression
|
||||||
''(import "''${nixos}/../lib").lib.systems.examples.aarch64-multiplatform'';
|
''(import "''${nixos}/../lib").lib.systems.examples.aarch64-multiplatform'';
|
||||||
description = ''
|
description = ''
|
||||||
Specifies the platform on which NixOS should be built. When
|
Specifies the platform on which NixOS should be built. When
|
||||||
|
|
|
@ -154,6 +154,7 @@
|
||||||
./programs/gnupg.nix
|
./programs/gnupg.nix
|
||||||
./programs/gphoto2.nix
|
./programs/gphoto2.nix
|
||||||
./programs/hamster.nix
|
./programs/hamster.nix
|
||||||
|
./programs/htop.nix
|
||||||
./programs/iftop.nix
|
./programs/iftop.nix
|
||||||
./programs/iotop.nix
|
./programs/iotop.nix
|
||||||
./programs/java.nix
|
./programs/java.nix
|
||||||
|
@ -984,6 +985,7 @@
|
||||||
./services/web-apps/jirafeau.nix
|
./services/web-apps/jirafeau.nix
|
||||||
./services/web-apps/jitsi-meet.nix
|
./services/web-apps/jitsi-meet.nix
|
||||||
./services/web-apps/keycloak.nix
|
./services/web-apps/keycloak.nix
|
||||||
|
./services/web-apps/lemmy.nix
|
||||||
./services/web-apps/limesurvey.nix
|
./services/web-apps/limesurvey.nix
|
||||||
./services/web-apps/mastodon.nix
|
./services/web-apps/mastodon.nix
|
||||||
./services/web-apps/mattermost.nix
|
./services/web-apps/mattermost.nix
|
||||||
|
|
|
@ -19,7 +19,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.atop;
|
default = pkgs.atop;
|
||||||
defaultText = "pkgs.atop";
|
defaultText = literalExpression "pkgs.atop";
|
||||||
description = ''
|
description = ''
|
||||||
Which package to use for Atop.
|
Which package to use for Atop.
|
||||||
'';
|
'';
|
||||||
|
@ -37,7 +37,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = config.boot.kernelPackages.netatop;
|
default = config.boot.kernelPackages.netatop;
|
||||||
defaultText = "config.boot.kernelPackages.netatop";
|
defaultText = literalExpression "config.boot.kernelPackages.netatop";
|
||||||
description = ''
|
description = ''
|
||||||
Which package to use for netatop.
|
Which package to use for netatop.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -14,7 +14,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.captive-browser;
|
default = pkgs.captive-browser;
|
||||||
defaultText = "pkgs.captive-browser";
|
defaultText = literalExpression "pkgs.captive-browser";
|
||||||
description = "Which package to use for captive-browser";
|
description = "Which package to use for captive-browser";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@ in {
|
||||||
|
|
||||||
# "nix-ccache --show-stats" and "nix-ccache --clear"
|
# "nix-ccache --show-stats" and "nix-ccache --clear"
|
||||||
security.wrappers.nix-ccache = {
|
security.wrappers.nix-ccache = {
|
||||||
owner = "nobody";
|
owner = "root";
|
||||||
group = "nixbld";
|
group = "nixbld";
|
||||||
setuid = false;
|
setuid = false;
|
||||||
setgid = true;
|
setgid = true;
|
||||||
|
|
|
@ -33,7 +33,7 @@ in
|
||||||
for additional details.
|
for additional details.
|
||||||
'';
|
'';
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[
|
[
|
||||||
"chlffgpmiacpedhhbkiomidkjlcfhogd" # pushbullet
|
"chlffgpmiacpedhhbkiomidkjlcfhogd" # pushbullet
|
||||||
"mbniclmhobmnbdlbpiphghaielnnpgdp" # lightshot
|
"mbniclmhobmnbdlbpiphghaielnnpgdp" # lightshot
|
||||||
|
@ -75,7 +75,7 @@ in
|
||||||
Make sure the selected policy is supported on Linux and your browser version.
|
Make sure the selected policy is supported on Linux and your browser version.
|
||||||
'';
|
'';
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"BrowserSignin" = 0;
|
"BrowserSignin" = 0;
|
||||||
"SyncDisabled" = true;
|
"SyncDisabled" = true;
|
||||||
|
|
|
@ -25,14 +25,7 @@ if (!defined $res || scalar @$res == 0) {
|
||||||
print STDERR "$program: command not found\n";
|
print STDERR "$program: command not found\n";
|
||||||
} elsif (scalar @$res == 1) {
|
} elsif (scalar @$res == 1) {
|
||||||
my $package = @$res[0]->{package};
|
my $package = @$res[0]->{package};
|
||||||
if ($ENV{"NIX_AUTO_INSTALL"} // "") {
|
if ($ENV{"NIX_AUTO_RUN"} // "") {
|
||||||
print STDERR <<EOF;
|
|
||||||
The program '$program' is currently not installed. It is provided by
|
|
||||||
the package '$package', which I will now install for you.
|
|
||||||
EOF
|
|
||||||
;
|
|
||||||
exit 126 if system("nix-env", "-iA", "nixos.$package") == 0;
|
|
||||||
} elsif ($ENV{"NIX_AUTO_RUN"} // "") {
|
|
||||||
exec("nix-shell", "-p", $package, "--run", shell_quote("exec", @ARGV));
|
exec("nix-shell", "-p", $package, "--run", shell_quote("exec", @ARGV));
|
||||||
} else {
|
} else {
|
||||||
print STDERR <<EOF;
|
print STDERR <<EOF;
|
||||||
|
|
|
@ -19,7 +19,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.digitalbitbox;
|
default = pkgs.digitalbitbox;
|
||||||
defaultText = "pkgs.digitalbitbox";
|
defaultText = literalExpression "pkgs.digitalbitbox";
|
||||||
description = "The Digital Bitbox package to use. This can be used to install a package with udev rules that differ from the defaults.";
|
description = "The Digital Bitbox package to use. This can be used to install a package with udev rules that differ from the defaults.";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -24,7 +24,7 @@ in {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
default = pkgs.dmrconfig;
|
default = pkgs.dmrconfig;
|
||||||
type = types.package;
|
type = types.package;
|
||||||
defaultText = "pkgs.dmrconfig";
|
defaultText = literalExpression "pkgs.dmrconfig";
|
||||||
description = "dmrconfig derivation to use";
|
description = "dmrconfig derivation to use";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -18,12 +18,16 @@ in
|
||||||
|
|
||||||
environment.variables =
|
environment.variables =
|
||||||
{ NIXPKGS_CONFIG = "/etc/nix/nixpkgs-config.nix";
|
{ NIXPKGS_CONFIG = "/etc/nix/nixpkgs-config.nix";
|
||||||
|
# note: many programs exec() this directly, so default options for less must not
|
||||||
|
# be specified here; do so in the default value of programs.less.envVariables instead
|
||||||
PAGER = mkDefault "less";
|
PAGER = mkDefault "less";
|
||||||
LESS = mkDefault "-R";
|
|
||||||
EDITOR = mkDefault "nano";
|
EDITOR = mkDefault "nano";
|
||||||
XDG_CONFIG_DIRS = [ "/etc/xdg" ]; # needs to be before profile-relative paths to allow changes through environment.etc
|
XDG_CONFIG_DIRS = [ "/etc/xdg" ]; # needs to be before profile-relative paths to allow changes through environment.etc
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# since we set PAGER to this above, make sure it's installed
|
||||||
|
programs.less.enable = true;
|
||||||
|
|
||||||
environment.profiles = mkAfter
|
environment.profiles = mkAfter
|
||||||
[ "/nix/var/nix/profiles/default"
|
[ "/nix/var/nix/profiles/default"
|
||||||
"/run/current-system/sw"
|
"/run/current-system/sw"
|
||||||
|
|
|
@ -18,6 +18,7 @@ in {
|
||||||
'';
|
'';
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.feedbackd;
|
default = pkgs.feedbackd;
|
||||||
|
defaultText = literalExpression "pkgs.feedbackd";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -40,13 +40,13 @@ in {
|
||||||
executable = mkOption {
|
executable = mkOption {
|
||||||
type = types.path;
|
type = types.path;
|
||||||
description = "Executable to run sandboxed";
|
description = "Executable to run sandboxed";
|
||||||
example = literalExample "''${lib.getBin pkgs.firefox}/bin/firefox";
|
example = literalExpression ''"''${lib.getBin pkgs.firefox}/bin/firefox"'';
|
||||||
};
|
};
|
||||||
profile = mkOption {
|
profile = mkOption {
|
||||||
type = types.nullOr types.path;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
description = "Profile to use";
|
description = "Profile to use";
|
||||||
example = literalExample "''${pkgs.firejail}/etc/firejail/firefox.profile";
|
example = literalExpression ''"''${pkgs.firejail}/etc/firejail/firefox.profile"'';
|
||||||
};
|
};
|
||||||
extraArgs = mkOption {
|
extraArgs = mkOption {
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
|
@ -57,7 +57,7 @@ in {
|
||||||
};
|
};
|
||||||
}));
|
}));
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
firefox = {
|
firefox = {
|
||||||
executable = "''${lib.getBin pkgs.firefox}/bin/firefox";
|
executable = "''${lib.getBin pkgs.firefox}/bin/firefox";
|
||||||
|
|
|
@ -13,7 +13,7 @@ in {
|
||||||
description = "FLEXOPTIX app package to use";
|
description = "FLEXOPTIX app package to use";
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.flexoptix-app;
|
default = pkgs.flexoptix-app;
|
||||||
defaultText = "\${pkgs.flexoptix-app}";
|
defaultText = literalExpression "pkgs.flexoptix-app";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -17,7 +17,7 @@ in
|
||||||
environment.freetds = mkOption {
|
environment.freetds = mkOption {
|
||||||
type = types.attrsOf types.str;
|
type = types.attrsOf types.str;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{ MYDATABASE = '''
|
{ MYDATABASE = '''
|
||||||
host = 10.0.2.100
|
host = 10.0.2.100
|
||||||
port = 1433
|
port = 1433
|
||||||
|
|
|
@ -23,7 +23,7 @@ in
|
||||||
System-wide configuration for GameMode (/etc/gamemode.ini).
|
System-wide configuration for GameMode (/etc/gamemode.ini).
|
||||||
See gamemoded(8) man page for available settings.
|
See gamemoded(8) man page for available settings.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
general = {
|
general = {
|
||||||
renice = 10;
|
renice = 10;
|
||||||
|
|
|
@ -14,8 +14,8 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.git;
|
default = pkgs.git;
|
||||||
defaultText = "pkgs.git";
|
defaultText = literalExpression "pkgs.git";
|
||||||
example = literalExample "pkgs.gitFull";
|
example = literalExpression "pkgs.gitFull";
|
||||||
description = "The git package to use";
|
description = "The git package to use";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.gnupg;
|
default = pkgs.gnupg;
|
||||||
defaultText = "pkgs.gnupg";
|
defaultText = literalExpression "pkgs.gnupg";
|
||||||
description = ''
|
description = ''
|
||||||
The gpg package that should be used.
|
The gpg package that should be used.
|
||||||
'';
|
'';
|
||||||
|
|
58
third_party/nixpkgs/nixos/modules/programs/htop.nix
vendored
Normal file
58
third_party/nixpkgs/nixos/modules/programs/htop.nix
vendored
Normal file
|
@ -0,0 +1,58 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
|
with lib;
|
||||||
|
|
||||||
|
let
|
||||||
|
|
||||||
|
cfg = config.programs.htop;
|
||||||
|
|
||||||
|
fmt = value:
|
||||||
|
if isList value then concatStringsSep " " (map fmt value) else
|
||||||
|
if isString value then value else
|
||||||
|
if isBool value || isInt value then toString value else
|
||||||
|
throw "Unrecognized type ${typeOf value} in htop settings";
|
||||||
|
|
||||||
|
in
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
options.programs.htop = {
|
||||||
|
package = mkOption {
|
||||||
|
type = types.package;
|
||||||
|
default = pkgs.htop;
|
||||||
|
defaultText = "pkgs.htop";
|
||||||
|
description = ''
|
||||||
|
The htop package that should be used.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
enable = mkEnableOption "htop process monitor";
|
||||||
|
|
||||||
|
settings = mkOption {
|
||||||
|
type = with types; attrsOf (oneOf [ str int bool (listOf (oneOf [ str int bool ])) ]);
|
||||||
|
default = {};
|
||||||
|
example = {
|
||||||
|
hide_kernel_threads = true;
|
||||||
|
hide_userland_threads = true;
|
||||||
|
};
|
||||||
|
description = ''
|
||||||
|
Extra global default configuration for htop
|
||||||
|
which is read on first startup only.
|
||||||
|
Htop subsequently uses ~/.config/htop/htoprc
|
||||||
|
as configuration source.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
environment.systemPackages = [
|
||||||
|
cfg.package
|
||||||
|
];
|
||||||
|
|
||||||
|
environment.etc."htoprc".text = ''
|
||||||
|
# Global htop configuration
|
||||||
|
# To change set: programs.htop.settings.KEY = VALUE;
|
||||||
|
'' + concatStringsSep "\n" (mapAttrsToList (key: value: "${key}=${fmt value}") cfg.settings);
|
||||||
|
};
|
||||||
|
|
||||||
|
}
|
|
@ -34,7 +34,7 @@ in
|
||||||
|
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
default = pkgs.jdk;
|
default = pkgs.jdk;
|
||||||
defaultText = "pkgs.jdk";
|
defaultText = literalExpression "pkgs.jdk";
|
||||||
description = ''
|
description = ''
|
||||||
Java package to install. Typical values are pkgs.jdk or pkgs.jre.
|
Java package to install. Typical values are pkgs.jdk or pkgs.jre.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -13,9 +13,9 @@ with lib;
|
||||||
'';
|
'';
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
default = pkgs.kdeconnect;
|
default = pkgs.kdeconnect;
|
||||||
defaultText = "pkgs.kdeconnect";
|
defaultText = literalExpression "pkgs.kdeconnect";
|
||||||
type = types.package;
|
type = types.package;
|
||||||
example = literalExample "pkgs.gnomeExtensions.gsconnect";
|
example = literalExpression "pkgs.gnomeExtensions.gsconnect";
|
||||||
description = ''
|
description = ''
|
||||||
The package providing the implementation for kdeconnect.
|
The package providing the implementation for kdeconnect.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -24,9 +24,7 @@ let
|
||||||
}
|
}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
lessKey = pkgs.runCommand "lesskey"
|
lessKey = pkgs.writeText "lessconfig" configText;
|
||||||
{ src = pkgs.writeText "lessconfig" configText; preferLocalBuild = true; }
|
|
||||||
"${pkgs.less}/bin/lesskey -o $out $src";
|
|
||||||
|
|
||||||
in
|
in
|
||||||
|
|
||||||
|
@ -35,12 +33,14 @@ in
|
||||||
|
|
||||||
programs.less = {
|
programs.less = {
|
||||||
|
|
||||||
|
# note that environment.nix sets PAGER=less, and
|
||||||
|
# therefore also enables this module
|
||||||
enable = mkEnableOption "less";
|
enable = mkEnableOption "less";
|
||||||
|
|
||||||
configFile = mkOption {
|
configFile = mkOption {
|
||||||
type = types.nullOr types.path;
|
type = types.nullOr types.path;
|
||||||
default = null;
|
default = null;
|
||||||
example = literalExample "\${pkgs.my-configs}/lesskey";
|
example = literalExpression ''"''${pkgs.my-configs}/lesskey"'';
|
||||||
description = ''
|
description = ''
|
||||||
Path to lesskey configuration file.
|
Path to lesskey configuration file.
|
||||||
|
|
||||||
|
@ -81,7 +81,9 @@ in
|
||||||
|
|
||||||
envVariables = mkOption {
|
envVariables = mkOption {
|
||||||
type = types.attrsOf types.str;
|
type = types.attrsOf types.str;
|
||||||
default = {};
|
default = {
|
||||||
|
LESS = "-R";
|
||||||
|
};
|
||||||
example = {
|
example = {
|
||||||
LESS = "--quit-if-one-screen";
|
LESS = "--quit-if-one-screen";
|
||||||
};
|
};
|
||||||
|
@ -91,6 +93,7 @@ in
|
||||||
lessopen = mkOption {
|
lessopen = mkOption {
|
||||||
type = types.nullOr types.str;
|
type = types.nullOr types.str;
|
||||||
default = "|${pkgs.lesspipe}/bin/lesspipe.sh %s";
|
default = "|${pkgs.lesspipe}/bin/lesspipe.sh %s";
|
||||||
|
defaultText = literalExpression ''"|''${pkgs.lesspipe}/bin/lesspipe.sh %s"'';
|
||||||
description = ''
|
description = ''
|
||||||
Before less opens a file, it first gives your input preprocessor a chance to modify the way the contents of the file are displayed.
|
Before less opens a file, it first gives your input preprocessor a chance to modify the way the contents of the file are displayed.
|
||||||
'';
|
'';
|
||||||
|
@ -111,7 +114,7 @@ in
|
||||||
environment.systemPackages = [ pkgs.less ];
|
environment.systemPackages = [ pkgs.less ];
|
||||||
|
|
||||||
environment.variables = {
|
environment.variables = {
|
||||||
LESSKEY_SYSTEM = toString lessKey;
|
LESSKEYIN_SYSTEM = toString lessKey;
|
||||||
} // optionalAttrs (cfg.lessopen != null) {
|
} // optionalAttrs (cfg.lessopen != null) {
|
||||||
LESSOPEN = cfg.lessopen;
|
LESSOPEN = cfg.lessopen;
|
||||||
} // optionalAttrs (cfg.lessclose != null) {
|
} // optionalAttrs (cfg.lessclose != null) {
|
||||||
|
|
|
@ -33,7 +33,7 @@ in
|
||||||
security.wrappers = mkIf cfg.withUtempter {
|
security.wrappers = mkIf cfg.withUtempter {
|
||||||
utempter = {
|
utempter = {
|
||||||
source = "${pkgs.libutempter}/lib/utempter/utempter";
|
source = "${pkgs.libutempter}/lib/utempter/utempter";
|
||||||
owner = "nobody";
|
owner = "root";
|
||||||
group = "utmp";
|
group = "utmp";
|
||||||
setuid = false;
|
setuid = false;
|
||||||
setgid = true;
|
setgid = true;
|
||||||
|
|
|
@ -20,6 +20,7 @@ in {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.mtr;
|
default = pkgs.mtr;
|
||||||
|
defaultText = literalExpression "pkgs.mtr";
|
||||||
description = ''
|
description = ''
|
||||||
The package to use.
|
The package to use.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -47,18 +47,18 @@ in {
|
||||||
configure = mkOption {
|
configure = mkOption {
|
||||||
type = types.attrs;
|
type = types.attrs;
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
configure = {
|
{
|
||||||
customRC = $''''
|
customRC = '''
|
||||||
" here your custom configuration goes!
|
" here your custom configuration goes!
|
||||||
$'''';
|
''';
|
||||||
packages.myVimPackage = with pkgs.vimPlugins; {
|
packages.myVimPackage = with pkgs.vimPlugins; {
|
||||||
# loaded on launch
|
# loaded on launch
|
||||||
start = [ fugitive ];
|
start = [ fugitive ];
|
||||||
# manually loadable by calling `:packadd $plugin-name`
|
# manually loadable by calling `:packadd $plugin-name`
|
||||||
opt = [ ];
|
opt = [ ];
|
||||||
};
|
};
|
||||||
};
|
}
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
Generate your init file from your list of plugins and custom commands.
|
Generate your init file from your list of plugins and custom commands.
|
||||||
|
@ -69,7 +69,7 @@ in {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.neovim-unwrapped;
|
default = pkgs.neovim-unwrapped;
|
||||||
defaultText = literalExample "pkgs.neovim-unwrapped";
|
defaultText = literalExpression "pkgs.neovim-unwrapped";
|
||||||
description = "The package to use for the neovim binary.";
|
description = "The package to use for the neovim binary.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -82,8 +82,8 @@ in {
|
||||||
|
|
||||||
runtime = mkOption {
|
runtime = mkOption {
|
||||||
default = {};
|
default = {};
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
runtime."ftplugin/c.vim".text = "setlocal omnifunc=v:lua.vim.lsp.omnifunc";
|
{ "ftplugin/c.vim".text = "setlocal omnifunc=v:lua.vim.lsp.omnifunc"; }
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
Set of files that have to be linked in <filename>runtime</filename>.
|
Set of files that have to be linked in <filename>runtime</filename>.
|
||||||
|
|
|
@ -10,6 +10,7 @@ in {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.noisetorch;
|
default = pkgs.noisetorch;
|
||||||
|
defaultText = literalExpression "pkgs.noisetorch";
|
||||||
description = ''
|
description = ''
|
||||||
The noisetorch package to use.
|
The noisetorch package to use.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -14,10 +14,11 @@ in
|
||||||
enable = mkEnableOption "<command>npm</command> global config";
|
enable = mkEnableOption "<command>npm</command> global config";
|
||||||
|
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.path;
|
type = types.package;
|
||||||
description = "The npm package version / flavor to use";
|
description = "The npm package version / flavor to use";
|
||||||
default = pkgs.nodePackages.npm;
|
default = pkgs.nodePackages.npm;
|
||||||
example = literalExample "pkgs.nodePackages_13_x.npm";
|
defaultText = literalExpression "pkgs.nodePackages.npm";
|
||||||
|
example = literalExpression "pkgs.nodePackages_13_x.npm";
|
||||||
};
|
};
|
||||||
|
|
||||||
npmrc = mkOption {
|
npmrc = mkOption {
|
||||||
|
|
|
@ -120,7 +120,7 @@ in {
|
||||||
Proxies to be used by proxychains.
|
Proxies to be used by proxychains.
|
||||||
'';
|
'';
|
||||||
|
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{ myproxy =
|
{ myproxy =
|
||||||
{ type = "socks4";
|
{ type = "socks4";
|
||||||
host = "127.0.0.1";
|
host = "127.0.0.1";
|
||||||
|
|
|
@ -66,7 +66,7 @@ in
|
||||||
This must not be a store path, since the path is
|
This must not be a store path, since the path is
|
||||||
used outside the store (in particular in /etc/passwd).
|
used outside the store (in particular in /etc/passwd).
|
||||||
'';
|
'';
|
||||||
example = literalExample "pkgs.zsh";
|
example = literalExpression "pkgs.zsh";
|
||||||
type = types.either types.path types.shellPackage;
|
type = types.either types.path types.shellPackage;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -29,11 +29,13 @@ in
|
||||||
terminal_su = "${pkgs.sudo}/bin/sudo";
|
terminal_su = "${pkgs.sudo}/bin/sudo";
|
||||||
graphical_su = "${pkgs.gksu}/bin/gksu";
|
graphical_su = "${pkgs.gksu}/bin/gksu";
|
||||||
};
|
};
|
||||||
example = literalExample ''{
|
defaultText = literalExpression ''
|
||||||
|
{
|
||||||
tmp_dir = "/tmp";
|
tmp_dir = "/tmp";
|
||||||
terminal_su = "''${pkgs.sudo}/bin/sudo";
|
terminal_su = "''${pkgs.sudo}/bin/sudo";
|
||||||
graphical_su = "''${pkgs.gksu}/bin/gksu";
|
graphical_su = "''${pkgs.gksu}/bin/gksu";
|
||||||
}'';
|
}
|
||||||
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
The system-wide spacefm configuration.
|
The system-wide spacefm configuration.
|
||||||
Parameters to be written to <filename>/etc/spacefm/spacefm.conf</filename>.
|
Parameters to be written to <filename>/etc/spacefm/spacefm.conf</filename>.
|
||||||
|
|
|
@ -36,6 +36,7 @@ in
|
||||||
askPassword = mkOption {
|
askPassword = mkOption {
|
||||||
type = types.str;
|
type = types.str;
|
||||||
default = "${pkgs.x11_ssh_askpass}/libexec/x11-ssh-askpass";
|
default = "${pkgs.x11_ssh_askpass}/libexec/x11-ssh-askpass";
|
||||||
|
defaultText = literalExpression ''"''${pkgs.x11_ssh_askpass}/libexec/x11-ssh-askpass"'';
|
||||||
description = "Program used by SSH to ask for passwords.";
|
description = "Program used by SSH to ask for passwords.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -113,7 +114,7 @@ in
|
||||||
agentPKCS11Whitelist = mkOption {
|
agentPKCS11Whitelist = mkOption {
|
||||||
type = types.nullOr types.str;
|
type = types.nullOr types.str;
|
||||||
default = null;
|
default = null;
|
||||||
example = "\${pkgs.opensc}/lib/opensc-pkcs11.so";
|
example = literalExpression ''"''${pkgs.opensc}/lib/opensc-pkcs11.so"'';
|
||||||
description = ''
|
description = ''
|
||||||
A pattern-list of acceptable paths for PKCS#11 shared libraries
|
A pattern-list of acceptable paths for PKCS#11 shared libraries
|
||||||
that may be used with the -s option to ssh-add.
|
that may be used with the -s option to ssh-add.
|
||||||
|
@ -123,7 +124,7 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.openssh;
|
default = pkgs.openssh;
|
||||||
defaultText = "pkgs.openssh";
|
defaultText = literalExpression "pkgs.openssh";
|
||||||
description = ''
|
description = ''
|
||||||
The package used for the openssh client and daemon.
|
The package used for the openssh client and daemon.
|
||||||
'';
|
'';
|
||||||
|
@ -180,7 +181,7 @@ in
|
||||||
description = ''
|
description = ''
|
||||||
The set of system-wide known SSH hosts.
|
The set of system-wide known SSH hosts.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
myhost = {
|
myhost = {
|
||||||
hostNames = [ "myhost" "myhost.mydomain.com" "10.10.1.4" ];
|
hostNames = [ "myhost" "myhost.mydomain.com" "10.10.1.4" ];
|
||||||
|
|
|
@ -54,7 +54,7 @@ in
|
||||||
<citerefentry><refentrytitle>ssmtp</refentrytitle><manvolnum>5</manvolnum></citerefentry> configuration. Refer
|
<citerefentry><refentrytitle>ssmtp</refentrytitle><manvolnum>5</manvolnum></citerefentry> configuration. Refer
|
||||||
to <link xlink:href="https://linux.die.net/man/5/ssmtp.conf"/> for details on supported values.
|
to <link xlink:href="https://linux.die.net/man/5/ssmtp.conf"/> for details on supported values.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
Debug = true;
|
Debug = true;
|
||||||
FromLineOverride = false;
|
FromLineOverride = false;
|
||||||
|
|
|
@ -92,10 +92,10 @@ in {
|
||||||
default = with pkgs; [
|
default = with pkgs; [
|
||||||
swaylock swayidle alacritty dmenu
|
swaylock swayidle alacritty dmenu
|
||||||
];
|
];
|
||||||
defaultText = literalExample ''
|
defaultText = literalExpression ''
|
||||||
with pkgs; [ swaylock swayidle alacritty dmenu ];
|
with pkgs; [ swaylock swayidle alacritty dmenu ];
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
with pkgs; [
|
with pkgs; [
|
||||||
i3status i3status-rust
|
i3status i3status-rust
|
||||||
termite rofi light
|
termite rofi light
|
||||||
|
|
|
@ -5,7 +5,7 @@ let
|
||||||
inherit (builtins) length map;
|
inherit (builtins) length map;
|
||||||
inherit (lib.attrsets) attrNames filterAttrs hasAttr mapAttrs mapAttrsToList optionalAttrs;
|
inherit (lib.attrsets) attrNames filterAttrs hasAttr mapAttrs mapAttrsToList optionalAttrs;
|
||||||
inherit (lib.modules) mkDefault mkIf;
|
inherit (lib.modules) mkDefault mkIf;
|
||||||
inherit (lib.options) literalExample mkEnableOption mkOption;
|
inherit (lib.options) literalExpression mkEnableOption mkOption;
|
||||||
inherit (lib.strings) concatStringsSep optionalString toLower;
|
inherit (lib.strings) concatStringsSep optionalString toLower;
|
||||||
inherit (lib.types) addCheck attrsOf lines nullOr package path port str strMatching submodule;
|
inherit (lib.types) addCheck attrsOf lines nullOr package path port str strMatching submodule;
|
||||||
|
|
||||||
|
@ -123,7 +123,7 @@ let
|
||||||
};
|
};
|
||||||
options.text = mkOption {
|
options.text = mkOption {
|
||||||
type = lines;
|
type = lines;
|
||||||
example = literalExample
|
example = literalExpression
|
||||||
''lib.modules.mkAfter "compression no"'';
|
''lib.modules.mkAfter "compression no"'';
|
||||||
description = ''
|
description = ''
|
||||||
Additional text lines for the server stanza.
|
Additional text lines for the server stanza.
|
||||||
|
@ -218,8 +218,8 @@ let
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = package;
|
type = package;
|
||||||
default = pkgs.tsm-client;
|
default = pkgs.tsm-client;
|
||||||
defaultText = "pkgs.tsm-client";
|
defaultText = literalExpression "pkgs.tsm-client";
|
||||||
example = literalExample "pkgs.tsm-client-withGui";
|
example = literalExpression "pkgs.tsm-client-withGui";
|
||||||
description = ''
|
description = ''
|
||||||
The TSM client derivation to be
|
The TSM client derivation to be
|
||||||
added to the system environment.
|
added to the system environment.
|
||||||
|
|
|
@ -18,8 +18,8 @@ in {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.vim;
|
default = pkgs.vim;
|
||||||
defaultText = "pkgs.vim";
|
defaultText = literalExpression "pkgs.vim";
|
||||||
example = "pkgs.vimHugeX";
|
example = literalExpression "pkgs.vimHugeX";
|
||||||
description = ''
|
description = ''
|
||||||
vim package to use.
|
vim package to use.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -19,7 +19,7 @@ in {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.wireshark-cli;
|
default = pkgs.wireshark-cli;
|
||||||
defaultText = "pkgs.wireshark-cli";
|
defaultText = literalExpression "pkgs.wireshark-cli";
|
||||||
description = ''
|
description = ''
|
||||||
Which Wireshark package to install in the global environment.
|
Which Wireshark package to install in the global environment.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -27,7 +27,8 @@ in
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
type = types.package;
|
type = types.package;
|
||||||
default = pkgs.xonsh;
|
default = pkgs.xonsh;
|
||||||
example = literalExample "pkgs.xonsh.override { configFile = \"/path/to/xonshrc\"; }";
|
defaultText = literalExpression "pkgs.xonsh";
|
||||||
|
example = literalExpression "pkgs.xonsh.override { configFile = \"/path/to/xonshrc\"; }";
|
||||||
description = ''
|
description = ''
|
||||||
xonsh package to use.
|
xonsh package to use.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -11,7 +11,8 @@ in
|
||||||
|
|
||||||
lockerCommand = mkOption {
|
lockerCommand = mkOption {
|
||||||
default = "${pkgs.i3lock}/bin/i3lock";
|
default = "${pkgs.i3lock}/bin/i3lock";
|
||||||
example = literalExample "\${pkgs.i3lock-fancy}/bin/i3lock-fancy";
|
defaultText = literalExpression ''"''${pkgs.i3lock}/bin/i3lock"'';
|
||||||
|
example = literalExpression ''"''${pkgs.i3lock-fancy}/bin/i3lock-fancy"'';
|
||||||
type = types.separatedString " ";
|
type = types.separatedString " ";
|
||||||
description = "Locker to be used with xsslock";
|
description = "Locker to be used with xsslock";
|
||||||
};
|
};
|
||||||
|
|
|
@ -16,9 +16,8 @@ in
|
||||||
type = types.str;
|
type = types.str;
|
||||||
default = optionalString config.fonts.fontDir.enable
|
default = optionalString config.fonts.fontDir.enable
|
||||||
"/run/current-system/sw/share/X11/fonts";
|
"/run/current-system/sw/share/X11/fonts";
|
||||||
defaultText = literalExample ''
|
defaultText = literalExpression ''
|
||||||
optionalString config.fonts.fontDir.enable
|
optionalString config.fonts.fontDir.enable "/run/current-system/sw/share/X11/fonts"
|
||||||
"/run/current-system/sw/share/X11/fonts";
|
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
Default font path. Setting this option causes Xwayland to be rebuilt.
|
Default font path. Setting this option causes Xwayland to be rebuilt.
|
||||||
|
@ -30,10 +29,10 @@ in
|
||||||
default = pkgs.xwayland.override (oldArgs: {
|
default = pkgs.xwayland.override (oldArgs: {
|
||||||
inherit (cfg) defaultFontPath;
|
inherit (cfg) defaultFontPath;
|
||||||
});
|
});
|
||||||
defaultText = literalExample ''
|
defaultText = literalExpression ''
|
||||||
pkgs.xwayland.override (oldArgs: {
|
pkgs.xwayland.override (oldArgs: {
|
||||||
inherit (config.programs.xwayland) defaultFontPath;
|
inherit (config.programs.xwayland) defaultFontPath;
|
||||||
});
|
})
|
||||||
'';
|
'';
|
||||||
description = "The Xwayland package to use.";
|
description = "The Xwayland package to use.";
|
||||||
};
|
};
|
||||||
|
|
|
@ -45,7 +45,8 @@ in
|
||||||
|
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
default = pkgs.yabar-unstable;
|
default = pkgs.yabar-unstable;
|
||||||
example = literalExample "pkgs.yabar";
|
defaultText = literalExpression "pkgs.yabar-unstable";
|
||||||
|
example = literalExpression "pkgs.yabar";
|
||||||
type = types.package;
|
type = types.package;
|
||||||
|
|
||||||
# `yabar-stable` segfaults under certain conditions.
|
# `yabar-stable` segfaults under certain conditions.
|
||||||
|
|
|
@ -48,7 +48,7 @@ in
|
||||||
|
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
default = pkgs.oh-my-zsh;
|
default = pkgs.oh-my-zsh;
|
||||||
defaultText = "pkgs.oh-my-zsh";
|
defaultText = literalExpression "pkgs.oh-my-zsh";
|
||||||
description = ''
|
description = ''
|
||||||
Package to install for `oh-my-zsh` usage.
|
Package to install for `oh-my-zsh` usage.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -10,7 +10,7 @@ in {
|
||||||
enable = mkEnableOption "zsh-autoenv";
|
enable = mkEnableOption "zsh-autoenv";
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
default = pkgs.zsh-autoenv;
|
default = pkgs.zsh-autoenv;
|
||||||
defaultText = "pkgs.zsh-autoenv";
|
defaultText = literalExpression "pkgs.zsh-autoenv";
|
||||||
description = ''
|
description = ''
|
||||||
Package to install for `zsh-autoenv` usage.
|
Package to install for `zsh-autoenv` usage.
|
||||||
'';
|
'';
|
||||||
|
|
|
@ -40,7 +40,7 @@ in
|
||||||
type = with types; attrsOf str;
|
type = with types; attrsOf str;
|
||||||
default = {};
|
default = {};
|
||||||
description = "Attribute set with additional configuration values";
|
description = "Attribute set with additional configuration values";
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE" = "20";
|
"ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE" = "20";
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,7 +42,7 @@ in
|
||||||
default = {};
|
default = {};
|
||||||
type = types.attrsOf types.str;
|
type = types.attrsOf types.str;
|
||||||
|
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"rm -rf *" = "fg=white,bold,bg=red";
|
"rm -rf *" = "fg=white,bold,bg=red";
|
||||||
}
|
}
|
||||||
|
@ -59,7 +59,7 @@ in
|
||||||
default = {};
|
default = {};
|
||||||
type = types.attrsOf types.str;
|
type = types.attrsOf types.str;
|
||||||
|
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"alias" = "fg=magenta,bold";
|
"alias" = "fg=magenta,bold";
|
||||||
}
|
}
|
||||||
|
|
|
@ -486,7 +486,7 @@ let
|
||||||
extraDomainNames = mkOption {
|
extraDomainNames = mkOption {
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[
|
[
|
||||||
"example.org"
|
"example.org"
|
||||||
"mydomain.org"
|
"mydomain.org"
|
||||||
|
@ -656,7 +656,7 @@ in {
|
||||||
to those units if they rely on the certificates being present,
|
to those units if they rely on the certificates being present,
|
||||||
or trigger restarts of the service if certificates get renewed.
|
or trigger restarts of the service if certificates get renewed.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
{
|
{
|
||||||
"example.com" = {
|
"example.com" = {
|
||||||
webroot = "/var/lib/acme/acme-challenge/";
|
webroot = "/var/lib/acme/acme-challenge/";
|
||||||
|
|
|
@ -24,7 +24,7 @@ in
|
||||||
security.pki.certificateFiles = mkOption {
|
security.pki.certificateFiles = mkOption {
|
||||||
type = types.listOf types.path;
|
type = types.listOf types.path;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ \"\${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt\" ]";
|
example = literalExpression ''[ "''${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt" ]'';
|
||||||
description = ''
|
description = ''
|
||||||
A list of files containing trusted root certificates in PEM
|
A list of files containing trusted root certificates in PEM
|
||||||
format. These are concatenated to form
|
format. These are concatenated to form
|
||||||
|
@ -37,7 +37,7 @@ in
|
||||||
security.pki.certificates = mkOption {
|
security.pki.certificates = mkOption {
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[ '''
|
[ '''
|
||||||
NixOS.org
|
NixOS.org
|
||||||
=========
|
=========
|
||||||
|
|
|
@ -53,7 +53,7 @@ in {
|
||||||
coerce = bits: { inherit bits; };
|
coerce = bits: { inherit bits; };
|
||||||
in attrsOf (coercedTo int coerce (submodule paramsSubmodule));
|
in attrsOf (coercedTo int coerce (submodule paramsSubmodule));
|
||||||
default = {};
|
default = {};
|
||||||
example = lib.literalExample "{ nginx.bits = 3072; }";
|
example = lib.literalExpression "{ nginx.bits = 3072; }";
|
||||||
description = ''
|
description = ''
|
||||||
Diffie-Hellman parameters to generate.
|
Diffie-Hellman parameters to generate.
|
||||||
|
|
||||||
|
|
|
@ -77,7 +77,7 @@ in
|
||||||
You can use <code>mkBefore</code> and/or <code>mkAfter</code> to ensure
|
You can use <code>mkBefore</code> and/or <code>mkAfter</code> to ensure
|
||||||
this is the case when configuration options are merged.
|
this is the case when configuration options are merged.
|
||||||
'';
|
'';
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[
|
[
|
||||||
# Allow execution of any command by any user in group doas, requiring
|
# Allow execution of any command by any user in group doas, requiring
|
||||||
# a password and keeping any previously-defined environment variables.
|
# a password and keeping any previously-defined environment variables.
|
||||||
|
|
|
@ -586,7 +586,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
security.pam.services = mkOption {
|
security.pam.services = mkOption {
|
||||||
default = [];
|
default = {};
|
||||||
type = with types; attrsOf (submodule pamOpts);
|
type = with types; attrsOf (submodule pamOpts);
|
||||||
description =
|
description =
|
||||||
''
|
''
|
||||||
|
|
|
@ -33,7 +33,7 @@ in
|
||||||
additionalSearchPaths = mkOption {
|
additionalSearchPaths = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample "[ pkgs.bindfs ]";
|
example = literalExpression "[ pkgs.bindfs ]";
|
||||||
description = ''
|
description = ''
|
||||||
Additional programs to include in the search path of pam_mount.
|
Additional programs to include in the search path of pam_mount.
|
||||||
Useful for example if you want to use some FUSE filesystems like bindfs.
|
Useful for example if you want to use some FUSE filesystems like bindfs.
|
||||||
|
@ -43,7 +43,7 @@ in
|
||||||
fuseMountOptions = mkOption {
|
fuseMountOptions = mkOption {
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
default = [];
|
default = [];
|
||||||
example = literalExample ''
|
example = literalExpression ''
|
||||||
[ "nodev" "nosuid" "force-user=%(USER)" "gid=%(USERGID)" "perms=0700" "chmod-deny" "chown-deny" "chgrp-deny" ]
|
[ "nodev" "nosuid" "force-user=%(USER)" "gid=%(USERGID)" "perms=0700" "chmod-deny" "chown-deny" "chgrp-deny" ]
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue