Merge branch 'nativeCheckInputs' into staging-nativeCheckInputs
This commit is contained in:
commit
90c78aee6c
2
.github/workflows/editorconfig.yml
vendored
2
.github/workflows/editorconfig.yml
vendored
|
@ -11,7 +11,7 @@ on:
|
||||||
jobs:
|
jobs:
|
||||||
tests:
|
tests:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: "github.repository_owner == 'NixOS' && !contains(github.event.pull_request.title, '[skip editorconfig]')"
|
if: "github.repository_owner == 'NixOS' && !contains(github.event.pull_request.title, '[skip treewide]')"
|
||||||
steps:
|
steps:
|
||||||
- name: Get list of changed files from PR
|
- name: Get list of changed files from PR
|
||||||
env:
|
env:
|
||||||
|
|
2
.github/workflows/labels.yml
vendored
2
.github/workflows/labels.yml
vendored
|
@ -16,7 +16,7 @@ permissions:
|
||||||
jobs:
|
jobs:
|
||||||
labels:
|
labels:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.repository_owner == 'NixOS'
|
if: "github.repository_owner == 'NixOS' && !contains(github.event.pull_request.title, '[skip treewide]')"
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/labeler@v4
|
- uses: actions/labeler@v4
|
||||||
with:
|
with:
|
||||||
|
|
|
@ -9,7 +9,7 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
# ...
|
# ...
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
postgresql
|
postgresql
|
||||||
postgresqlTestHook
|
postgresqlTestHook
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
# Haskell {#haskell}
|
# Haskell {#haskell}
|
||||||
|
|
||||||
The Haskell infrastructure in nixpkgs has two main purposes: The primary purpose
|
The Haskell infrastructure in Nixpkgs has two main purposes: The primary purpose
|
||||||
is to provide a Haskell compiler and build tools as well as infrastructure for
|
is to provide a Haskell compiler and build tools as well as infrastructure for
|
||||||
packaging Haskell-based packages.
|
packaging Haskell-based packages.
|
||||||
|
|
||||||
The secondary purpose is to provide support for Haskell development environment
|
The secondary purpose is to provide support for Haskell development environments
|
||||||
including prebuilt Haskell libraries. However, in this area sacrifices have been
|
including prebuilt Haskell libraries. However, in this area sacrifices have been
|
||||||
made due to self-imposed restrictions in nixpkgs, to lessen the maintenance
|
made due to self-imposed restrictions in Nixpkgs, to lessen the maintenance
|
||||||
effort and improve performance. (More details in the subsection
|
effort and to improve performance. (More details in the subsection
|
||||||
[Limitations.](#haskell-limitations))
|
[Limitations.](#haskell-limitations))
|
||||||
|
|
||||||
## Available packages {#haskell-available-packages}
|
## Available packages {#haskell-available-packages}
|
||||||
|
@ -18,17 +18,17 @@ The compiler and most build tools are exposed at the top level:
|
||||||
* Language specific tools: `cabal-install`, `stack`, `hpack`, …
|
* Language specific tools: `cabal-install`, `stack`, `hpack`, …
|
||||||
|
|
||||||
Many “normal” user facing packages written in Haskell, like `niv` or `cachix`,
|
Many “normal” user facing packages written in Haskell, like `niv` or `cachix`,
|
||||||
are also exposed at the top level, so there is nothing haskell specific to
|
are also exposed at the top level, and there is nothing Haskell specific to
|
||||||
installing and using them.
|
installing and using them.
|
||||||
|
|
||||||
All of these packages originally are defined in the `haskellPackages` package
|
All of these packages are originally defined in the `haskellPackages` package
|
||||||
set and are re-exposed with a reduced dependency closure for convenience.
|
set and are re-exposed with a reduced dependency closure for convenience.
|
||||||
(see `justStaticExecutables` below)
|
(see `justStaticExecutables` below)
|
||||||
|
|
||||||
The `haskellPackages` set includes at least one version of every package from
|
The `haskellPackages` set includes at least one version of every package from
|
||||||
Hackage as well as some manually injected packages. This amounts to a lot of
|
Hackage as well as some manually injected packages. This amounts to a lot of
|
||||||
packages, so it is hidden from `nix-env -qa` by default for performance reasons.
|
packages, so it is hidden from `nix-env -qa` by default for performance reasons.
|
||||||
You can still list all packages in the set like this, though:
|
You can still list all packages in the set like this:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ nix-env -f '<nixpkgs>' -qaP -A haskellPackages
|
$ nix-env -f '<nixpkgs>' -qaP -A haskellPackages
|
||||||
|
@ -39,22 +39,22 @@ haskellPackages.abacate abac
|
||||||
haskellPackages.abc-puzzle abc-puzzle-0.2.1
|
haskellPackages.abc-puzzle abc-puzzle-0.2.1
|
||||||
…
|
…
|
||||||
```
|
```
|
||||||
Also the default set `haskellPackages` is included on [search.nixos.org].
|
Also, the `haskellPackages` set is included on [search.nixos.org].
|
||||||
|
|
||||||
The attribute names in `haskellPackages` always correspond with their name on
|
The attribute names in `haskellPackages` always correspond with their name on
|
||||||
Hackage. Since Hackage allows names that are not valid Nix without extra
|
Hackage. Since Hackage allows names that are not valid Nix without escaping,
|
||||||
escaping, you sometimes need to extra care when handling attribute names like
|
you need to take care when handling attribute names like `3dmodels`.
|
||||||
`3dmodels`.
|
|
||||||
|
|
||||||
For packages that are part of [Stackage], we use the version prescribed by a
|
For packages that are part of [Stackage], we use the version prescribed by a
|
||||||
Stackage solver (usually the current LTS one) as the default version. For all
|
Stackage solver (usually the current LTS one) as the default version. For all
|
||||||
other packages we use the latest version from Hackage. See
|
other packages we use the latest version from Hackage. See
|
||||||
[below](#haskell-available-versions) to learn which versions exactly are provided.
|
[below](#haskell-available-versions) to learn which versions are provided
|
||||||
|
exactly.
|
||||||
|
|
||||||
Roughly half of the 16K packages contained in `haskellPackages` don't actually
|
Roughly half of the 16K packages contained in `haskellPackages` don't actually
|
||||||
build and are marked as broken semi-automatically. Most of those packages are
|
build and are marked as broken semi-automatically. Most of those packages are
|
||||||
deprecated or unmaintained, but sometimes packages that should, don't build.
|
deprecated or unmaintained, but sometimes packages that should build, do not
|
||||||
Very often fixing them is not a lot of work.
|
build. Very often fixing them is not a lot of work.
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
TODO(@sternenseemann):
|
TODO(@sternenseemann):
|
||||||
|
@ -101,11 +101,11 @@ haskell.compiler.native-bignum.ghcHEAD ghc-native-bignum-9.7.20221224
|
||||||
haskell.compiler.ghcjs ghcjs-8.10.7
|
haskell.compiler.ghcjs ghcjs-8.10.7
|
||||||
```
|
```
|
||||||
|
|
||||||
Every of those compilers has a corresponding attribute set built completely
|
Each of those compiler versions has a corresponding attribute set built using
|
||||||
using it. However, the non-standard package sets are not tested regularly and
|
it. However, the non-standard package sets are not tested regularly and, as a
|
||||||
have less working packages as a result. The corresponding package set for GHC
|
result, contain fewer working packages. The corresponding package set for GHC
|
||||||
9.4.4 is `haskell.packages.ghc944` (in fact `haskellPackages` is just an alias
|
9.4.4 is `haskell.packages.ghc944`. In fact `haskellPackages` is just an alias
|
||||||
for `haskell.packages.ghc924`):
|
for `haskell.packages.ghc924`:
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ nix-env -f '<nixpkgs>' -qaP -A haskell.packages.ghc924
|
$ nix-env -f '<nixpkgs>' -qaP -A haskell.packages.ghc924
|
||||||
|
|
|
@ -436,7 +436,7 @@ arguments `buildInputs` and `propagatedBuildInputs` to specify dependencies. If
|
||||||
something is exclusively a build-time dependency, then the dependency should be
|
something is exclusively a build-time dependency, then the dependency should be
|
||||||
included in `buildInputs`, but if it is (also) a runtime dependency, then it
|
included in `buildInputs`, but if it is (also) a runtime dependency, then it
|
||||||
should be added to `propagatedBuildInputs`. Test dependencies are considered
|
should be added to `propagatedBuildInputs`. Test dependencies are considered
|
||||||
build-time dependencies and passed to `checkInputs`.
|
build-time dependencies and passed to `nativeCheckInputs`.
|
||||||
|
|
||||||
The following example shows which arguments are given to `buildPythonPackage` in
|
The following example shows which arguments are given to `buildPythonPackage` in
|
||||||
order to build [`datashape`](https://github.com/blaze/datashape).
|
order to build [`datashape`](https://github.com/blaze/datashape).
|
||||||
|
@ -453,7 +453,7 @@ buildPythonPackage rec {
|
||||||
hash = "sha256-FLLvdm1MllKrgTGC6Gb0k0deZeVYvtCCLji/B7uhong=";
|
hash = "sha256-FLLvdm1MllKrgTGC6Gb0k0deZeVYvtCCLji/B7uhong=";
|
||||||
};
|
};
|
||||||
|
|
||||||
checkInputs = [ pytest ];
|
nativeCheckInputs = [ pytest ];
|
||||||
propagatedBuildInputs = [ numpy multipledispatch python-dateutil ];
|
propagatedBuildInputs = [ numpy multipledispatch python-dateutil ];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
|
@ -466,7 +466,7 @@ buildPythonPackage rec {
|
||||||
```
|
```
|
||||||
|
|
||||||
We can see several runtime dependencies, `numpy`, `multipledispatch`, and
|
We can see several runtime dependencies, `numpy`, `multipledispatch`, and
|
||||||
`python-dateutil`. Furthermore, we have one `checkInputs`, i.e. `pytest`. `pytest` is a
|
`python-dateutil`. Furthermore, we have one `nativeCheckInputs`, i.e. `pytest`. `pytest` is a
|
||||||
test runner and is only used during the `checkPhase` and is therefore not added
|
test runner and is only used during the `checkPhase` and is therefore not added
|
||||||
to `propagatedBuildInputs`.
|
to `propagatedBuildInputs`.
|
||||||
|
|
||||||
|
@ -569,7 +569,7 @@ Pytest is the most common test runner for python repositories. A trivial
|
||||||
test run would be:
|
test run would be:
|
||||||
|
|
||||||
```
|
```
|
||||||
checkInputs = [ pytest ];
|
nativeCheckInputs = [ pytest ];
|
||||||
checkPhase = ''
|
checkPhase = ''
|
||||||
runHook preCheck
|
runHook preCheck
|
||||||
|
|
||||||
|
@ -585,7 +585,7 @@ sandbox, and will generally need many tests to be disabled.
|
||||||
To filter tests using pytest, one can do the following:
|
To filter tests using pytest, one can do the following:
|
||||||
|
|
||||||
```
|
```
|
||||||
checkInputs = [ pytest ];
|
nativeCheckInputs = [ pytest ];
|
||||||
# avoid tests which need additional data or touch network
|
# avoid tests which need additional data or touch network
|
||||||
checkPhase = ''
|
checkPhase = ''
|
||||||
runHook preCheck
|
runHook preCheck
|
||||||
|
@ -618,7 +618,7 @@ when a package may need many items disabled to run the test suite.
|
||||||
Using the example above, the analogous `pytestCheckHook` usage would be:
|
Using the example above, the analogous `pytestCheckHook` usage would be:
|
||||||
|
|
||||||
```
|
```
|
||||||
checkInputs = [ pytestCheckHook ];
|
nativeCheckInputs = [ pytestCheckHook ];
|
||||||
|
|
||||||
# requires additional data
|
# requires additional data
|
||||||
pytestFlagsArray = [ "tests/" "--ignore=tests/integration" ];
|
pytestFlagsArray = [ "tests/" "--ignore=tests/integration" ];
|
||||||
|
@ -749,7 +749,7 @@ with the exception of `other` (see `format` in
|
||||||
`unittestCheckHook` is a hook which will substitute the setuptools `test` command for a `checkPhase` which runs `python -m unittest discover`:
|
`unittestCheckHook` is a hook which will substitute the setuptools `test` command for a `checkPhase` which runs `python -m unittest discover`:
|
||||||
|
|
||||||
```
|
```
|
||||||
checkInputs = [ unittestCheckHook ];
|
nativeCheckInputs = [ unittestCheckHook ];
|
||||||
|
|
||||||
unittestFlags = [ "-s" "tests" "-v" ];
|
unittestFlags = [ "-s" "tests" "-v" ];
|
||||||
```
|
```
|
||||||
|
@ -1006,7 +1006,7 @@ buildPythonPackage rec {
|
||||||
rm testing/test_argcomplete.py
|
rm testing/test_argcomplete.py
|
||||||
'';
|
'';
|
||||||
|
|
||||||
checkInputs = [ hypothesis ];
|
nativeCheckInputs = [ hypothesis ];
|
||||||
nativeBuildInputs = [ setuptools-scm ];
|
nativeBuildInputs = [ setuptools-scm ];
|
||||||
propagatedBuildInputs = [ attrs py setuptools six pluggy ];
|
propagatedBuildInputs = [ attrs py setuptools six pluggy ];
|
||||||
|
|
||||||
|
@ -1028,7 +1028,7 @@ The `buildPythonPackage` mainly does four things:
|
||||||
* In the `installCheck` phase, `${python.interpreter} setup.py test` is run.
|
* In the `installCheck` phase, `${python.interpreter} setup.py test` is run.
|
||||||
|
|
||||||
By default tests are run because `doCheck = true`. Test dependencies, like
|
By default tests are run because `doCheck = true`. Test dependencies, like
|
||||||
e.g. the test runner, should be added to `checkInputs`.
|
e.g. the test runner, should be added to `nativeCheckInputs`.
|
||||||
|
|
||||||
By default `meta.platforms` is set to the same value
|
By default `meta.platforms` is set to the same value
|
||||||
as the interpreter unless overridden otherwise.
|
as the interpreter unless overridden otherwise.
|
||||||
|
@ -1082,7 +1082,7 @@ because their behaviour is different:
|
||||||
* `buildInputs ? []`: Build and/or run-time dependencies that need to be
|
* `buildInputs ? []`: Build and/or run-time dependencies that need to be
|
||||||
compiled for the host machine. Typically non-Python libraries which are being
|
compiled for the host machine. Typically non-Python libraries which are being
|
||||||
linked.
|
linked.
|
||||||
* `checkInputs ? []`: Dependencies needed for running the `checkPhase`. These
|
* `nativeCheckInputs ? []`: Dependencies needed for running the `checkPhase`. These
|
||||||
are added to `nativeBuildInputs` when `doCheck = true`. Items listed in
|
are added to `nativeBuildInputs` when `doCheck = true`. Items listed in
|
||||||
`tests_require` go here.
|
`tests_require` go here.
|
||||||
* `propagatedBuildInputs ? []`: Aside from propagating dependencies,
|
* `propagatedBuildInputs ? []`: Aside from propagating dependencies,
|
||||||
|
@ -1416,7 +1416,7 @@ example of such a situation is when `py.test` is used.
|
||||||
buildPythonPackage {
|
buildPythonPackage {
|
||||||
# ...
|
# ...
|
||||||
# assumes the tests are located in tests
|
# assumes the tests are located in tests
|
||||||
checkInputs = [ pytest ];
|
nativeCheckInputs = [ pytest ];
|
||||||
checkPhase = ''
|
checkPhase = ''
|
||||||
runHook preCheck
|
runHook preCheck
|
||||||
|
|
||||||
|
@ -1768,7 +1768,7 @@ In a `setup.py` or `setup.cfg` it is common to declare dependencies:
|
||||||
|
|
||||||
* `setup_requires` corresponds to `nativeBuildInputs`
|
* `setup_requires` corresponds to `nativeBuildInputs`
|
||||||
* `install_requires` corresponds to `propagatedBuildInputs`
|
* `install_requires` corresponds to `propagatedBuildInputs`
|
||||||
* `tests_require` corresponds to `checkInputs`
|
* `tests_require` corresponds to `nativeCheckInputs`
|
||||||
|
|
||||||
## Contributing {#contributing}
|
## Contributing {#contributing}
|
||||||
|
|
||||||
|
|
|
@ -150,7 +150,7 @@ depsBuildBuild = [ buildPackages.stdenv.cc ];
|
||||||
Add the following to your `mkDerivation` invocation.
|
Add the following to your `mkDerivation` invocation.
|
||||||
|
|
||||||
```nix
|
```nix
|
||||||
doCheck = stdenv.hostPlatform == stdenv.buildPlatform;
|
doCheck = stdenv.buildPlatform.canExecute stdenv.hostPlatform;
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Package using Meson needs to run binaries for the host platform during build. {#cross-meson-runs-host-code}
|
#### Package using Meson needs to run binaries for the host platform during build. {#cross-meson-runs-host-code}
|
||||||
|
|
|
@ -654,7 +654,11 @@ A list of strings passed as additional flags to `make`. Like `makeFlags` and `ma
|
||||||
|
|
||||||
##### `checkInputs` {#var-stdenv-checkInputs}
|
##### `checkInputs` {#var-stdenv-checkInputs}
|
||||||
|
|
||||||
A list of dependencies used by the phase. This gets included in `nativeBuildInputs` when `doCheck` is set.
|
A list of host dependencies used by the phase, usually libraries linked into executables built during tests. This gets included in `buildInputs` when `doCheck` is set.
|
||||||
|
|
||||||
|
##### `nativeCheckInputs` {#var-stdenv-nativeCheckInputs}
|
||||||
|
|
||||||
|
A list of native dependencies used by the phase, notably tools needed on `$PATH`. This gets included in `nativeBuildInputs` when `doCheck` is set.
|
||||||
|
|
||||||
##### `preCheck` {#var-stdenv-preCheck}
|
##### `preCheck` {#var-stdenv-preCheck}
|
||||||
|
|
||||||
|
@ -821,7 +825,11 @@ A list of strings passed as additional flags to `make`. Like `makeFlags` and `ma
|
||||||
|
|
||||||
##### `installCheckInputs` {#var-stdenv-installCheckInputs}
|
##### `installCheckInputs` {#var-stdenv-installCheckInputs}
|
||||||
|
|
||||||
A list of dependencies used by the phase. This gets included in `nativeBuildInputs` when `doInstallCheck` is set.
|
A list of host dependencies used by the phase, usually libraries linked into executables built during tests. This gets included in `buildInputs` when `doInstallCheck` is set.
|
||||||
|
|
||||||
|
##### `nativeInstallCheckInputs` {#var-stdenv-nativeInstallCheckInputs}
|
||||||
|
|
||||||
|
A list of native dependencies used by the phase, notably tools needed on `$PATH`. This gets included in `nativeBuildInputs` when `doInstallCheck` is set.
|
||||||
|
|
||||||
##### `preInstallCheck` {#var-stdenv-preInstallCheck}
|
##### `preInstallCheck` {#var-stdenv-preInstallCheck}
|
||||||
|
|
||||||
|
|
|
@ -107,7 +107,7 @@ rec {
|
||||||
# Same as `makeExtensible` but the name of the extending attribute is
|
# Same as `makeExtensible` but the name of the extending attribute is
|
||||||
# customized.
|
# customized.
|
||||||
makeExtensibleWithCustomName = extenderName: rattrs:
|
makeExtensibleWithCustomName = extenderName: rattrs:
|
||||||
fix' rattrs // {
|
fix' (self: (rattrs self) // {
|
||||||
${extenderName} = f: makeExtensibleWithCustomName extenderName (extends f rattrs);
|
${extenderName} = f: makeExtensibleWithCustomName extenderName (extends f rattrs);
|
||||||
};
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -68,6 +68,7 @@ in {
|
||||||
none = [];
|
none = [];
|
||||||
|
|
||||||
arm = filterDoubles predicates.isAarch32;
|
arm = filterDoubles predicates.isAarch32;
|
||||||
|
armv7 = filterDoubles predicates.isArmv7;
|
||||||
aarch64 = filterDoubles predicates.isAarch64;
|
aarch64 = filterDoubles predicates.isAarch64;
|
||||||
x86 = filterDoubles predicates.isx86;
|
x86 = filterDoubles predicates.isx86;
|
||||||
i686 = filterDoubles predicates.isi686;
|
i686 = filterDoubles predicates.isi686;
|
||||||
|
@ -75,6 +76,7 @@ in {
|
||||||
microblaze = filterDoubles predicates.isMicroBlaze;
|
microblaze = filterDoubles predicates.isMicroBlaze;
|
||||||
mips = filterDoubles predicates.isMips;
|
mips = filterDoubles predicates.isMips;
|
||||||
mmix = filterDoubles predicates.isMmix;
|
mmix = filterDoubles predicates.isMmix;
|
||||||
|
power = filterDoubles predicates.isPower;
|
||||||
riscv = filterDoubles predicates.isRiscV;
|
riscv = filterDoubles predicates.isRiscV;
|
||||||
riscv32 = filterDoubles predicates.isRiscV32;
|
riscv32 = filterDoubles predicates.isRiscV32;
|
||||||
riscv64 = filterDoubles predicates.isRiscV64;
|
riscv64 = filterDoubles predicates.isRiscV64;
|
||||||
|
@ -83,6 +85,7 @@ in {
|
||||||
or1k = filterDoubles predicates.isOr1k;
|
or1k = filterDoubles predicates.isOr1k;
|
||||||
m68k = filterDoubles predicates.isM68k;
|
m68k = filterDoubles predicates.isM68k;
|
||||||
s390 = filterDoubles predicates.isS390;
|
s390 = filterDoubles predicates.isS390;
|
||||||
|
s390x = filterDoubles predicates.isS390x;
|
||||||
js = filterDoubles predicates.isJavaScript;
|
js = filterDoubles predicates.isJavaScript;
|
||||||
|
|
||||||
bigEndian = filterDoubles predicates.isBigEndian;
|
bigEndian = filterDoubles predicates.isBigEndian;
|
||||||
|
|
|
@ -22,6 +22,9 @@ rec {
|
||||||
];
|
];
|
||||||
isx86 = { cpu = { family = "x86"; }; };
|
isx86 = { cpu = { family = "x86"; }; };
|
||||||
isAarch32 = { cpu = { family = "arm"; bits = 32; }; };
|
isAarch32 = { cpu = { family = "arm"; bits = 32; }; };
|
||||||
|
isArmv7 = map ({ arch, ... }: { cpu = { inherit arch; }; })
|
||||||
|
(lib.filter (cpu: lib.hasPrefix "armv7" cpu.arch or "")
|
||||||
|
(lib.attrValues cpuTypes));
|
||||||
isAarch64 = { cpu = { family = "arm"; bits = 64; }; };
|
isAarch64 = { cpu = { family = "arm"; bits = 64; }; };
|
||||||
isAarch = { cpu = { family = "arm"; }; };
|
isAarch = { cpu = { family = "arm"; }; };
|
||||||
isMicroBlaze = { cpu = { family = "microblaze"; }; };
|
isMicroBlaze = { cpu = { family = "microblaze"; }; };
|
||||||
|
@ -44,6 +47,7 @@ rec {
|
||||||
isOr1k = { cpu = { family = "or1k"; }; };
|
isOr1k = { cpu = { family = "or1k"; }; };
|
||||||
isM68k = { cpu = { family = "m68k"; }; };
|
isM68k = { cpu = { family = "m68k"; }; };
|
||||||
isS390 = { cpu = { family = "s390"; }; };
|
isS390 = { cpu = { family = "s390"; }; };
|
||||||
|
isS390x = { cpu = { family = "s390"; bits = 64; }; };
|
||||||
isJavaScript = { cpu = cpuTypes.js; };
|
isJavaScript = { cpu = cpuTypes.js; };
|
||||||
|
|
||||||
is32bit = { cpu = { bits = 32; }; };
|
is32bit = { cpu = { bits = 32; }; };
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
{ # The pkgs used for dependencies for the testing itself
|
{ # The pkgs used for dependencies for the testing itself
|
||||||
# Don't test properties of pkgs.lib, but rather the lib in the parent directory
|
# Don't test properties of pkgs.lib, but rather the lib in the parent directory
|
||||||
pkgs ? import ../.. {} // { lib = throw "pkgs.lib accessed, but the lib tests should use nixpkgs' lib path directly!"; }
|
pkgs ? import ../.. {} // { lib = throw "pkgs.lib accessed, but the lib tests should use nixpkgs' lib path directly!"; },
|
||||||
|
nix ? pkgs.nix,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
pkgs.runCommand "nixpkgs-lib-tests" {
|
pkgs.runCommand "nixpkgs-lib-tests" {
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
pkgs.nix
|
|
||||||
(import ./check-eval.nix)
|
(import ./check-eval.nix)
|
||||||
(import ./maintainers.nix {
|
(import ./maintainers.nix {
|
||||||
inherit pkgs;
|
inherit pkgs;
|
||||||
|
@ -19,8 +19,12 @@ pkgs.runCommand "nixpkgs-lib-tests" {
|
||||||
inherit pkgs;
|
inherit pkgs;
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
nativeBuildInputs = [
|
||||||
|
nix
|
||||||
|
];
|
||||||
|
strictDeps = true;
|
||||||
} ''
|
} ''
|
||||||
datadir="${pkgs.nix}/share"
|
datadir="${nix}/share"
|
||||||
export TEST_ROOT=$(pwd)/test-tmp
|
export TEST_ROOT=$(pwd)/test-tmp
|
||||||
export NIX_BUILD_HOOK=
|
export NIX_BUILD_HOOK=
|
||||||
export NIX_CONF_DIR=$TEST_ROOT/etc
|
export NIX_CONF_DIR=$TEST_ROOT/etc
|
||||||
|
|
|
@ -16,12 +16,15 @@ with lib.systems.doubles; lib.runTests {
|
||||||
testall = mseteq all (linux ++ darwin ++ freebsd ++ openbsd ++ netbsd ++ illumos ++ wasi ++ windows ++ embedded ++ mmix ++ js ++ genode ++ redox);
|
testall = mseteq all (linux ++ darwin ++ freebsd ++ openbsd ++ netbsd ++ illumos ++ wasi ++ windows ++ embedded ++ mmix ++ js ++ genode ++ redox);
|
||||||
|
|
||||||
testarm = mseteq arm [ "armv5tel-linux" "armv6l-linux" "armv6l-netbsd" "armv6l-none" "armv7a-linux" "armv7a-netbsd" "armv7l-linux" "armv7l-netbsd" "arm-none" "armv7a-darwin" ];
|
testarm = mseteq arm [ "armv5tel-linux" "armv6l-linux" "armv6l-netbsd" "armv6l-none" "armv7a-linux" "armv7a-netbsd" "armv7l-linux" "armv7l-netbsd" "arm-none" "armv7a-darwin" ];
|
||||||
|
testarmv7 = mseteq armv7 [ "armv7a-darwin" "armv7a-linux" "armv7l-linux" "armv7a-netbsd" "armv7l-netbsd" ];
|
||||||
testi686 = mseteq i686 [ "i686-linux" "i686-freebsd13" "i686-genode" "i686-netbsd" "i686-openbsd" "i686-cygwin" "i686-windows" "i686-none" "i686-darwin" ];
|
testi686 = mseteq i686 [ "i686-linux" "i686-freebsd13" "i686-genode" "i686-netbsd" "i686-openbsd" "i686-cygwin" "i686-windows" "i686-none" "i686-darwin" ];
|
||||||
testmips = mseteq mips [ "mips64el-linux" "mipsel-linux" "mipsel-netbsd" ];
|
testmips = mseteq mips [ "mips64el-linux" "mipsel-linux" "mipsel-netbsd" ];
|
||||||
testmmix = mseteq mmix [ "mmix-mmixware" ];
|
testmmix = mseteq mmix [ "mmix-mmixware" ];
|
||||||
|
testpower = mseteq power [ "powerpc-netbsd" "powerpc-none" "powerpc64-linux" "powerpc64le-linux" "powerpcle-none" ];
|
||||||
testriscv = mseteq riscv [ "riscv32-linux" "riscv64-linux" "riscv32-netbsd" "riscv64-netbsd" "riscv32-none" "riscv64-none" ];
|
testriscv = mseteq riscv [ "riscv32-linux" "riscv64-linux" "riscv32-netbsd" "riscv64-netbsd" "riscv32-none" "riscv64-none" ];
|
||||||
testriscv32 = mseteq riscv32 [ "riscv32-linux" "riscv32-netbsd" "riscv32-none" ];
|
testriscv32 = mseteq riscv32 [ "riscv32-linux" "riscv32-netbsd" "riscv32-none" ];
|
||||||
testriscv64 = mseteq riscv64 [ "riscv64-linux" "riscv64-netbsd" "riscv64-none" ];
|
testriscv64 = mseteq riscv64 [ "riscv64-linux" "riscv64-netbsd" "riscv64-none" ];
|
||||||
|
tests390x = mseteq s390x [ "s390x-linux" "s390x-none" ];
|
||||||
testx86_64 = mseteq x86_64 [ "x86_64-linux" "x86_64-darwin" "x86_64-freebsd13" "x86_64-genode" "x86_64-redox" "x86_64-openbsd" "x86_64-netbsd" "x86_64-cygwin" "x86_64-solaris" "x86_64-windows" "x86_64-none" ];
|
testx86_64 = mseteq x86_64 [ "x86_64-linux" "x86_64-darwin" "x86_64-freebsd13" "x86_64-genode" "x86_64-redox" "x86_64-openbsd" "x86_64-netbsd" "x86_64-cygwin" "x86_64-solaris" "x86_64-windows" "x86_64-none" ];
|
||||||
|
|
||||||
testcygwin = mseteq cygwin [ "i686-cygwin" "x86_64-cygwin" ];
|
testcygwin = mseteq cygwin [ "i686-cygwin" "x86_64-cygwin" ];
|
||||||
|
|
|
@ -1330,6 +1330,12 @@
|
||||||
githubId = 55833;
|
githubId = 55833;
|
||||||
name = "Troels Henriksen";
|
name = "Troels Henriksen";
|
||||||
};
|
};
|
||||||
|
athre0z = {
|
||||||
|
email = "joel@zyantific.com";
|
||||||
|
github = "athre0z";
|
||||||
|
githubId = 6553158;
|
||||||
|
name = "Joel Höner";
|
||||||
|
};
|
||||||
atila = {
|
atila = {
|
||||||
name = "Átila Saraiva";
|
name = "Átila Saraiva";
|
||||||
email = "atilasaraiva@gmail.com";
|
email = "atilasaraiva@gmail.com";
|
||||||
|
@ -4189,6 +4195,12 @@
|
||||||
githubId = 5300871;
|
githubId = 5300871;
|
||||||
name = "Leon Kowarschick";
|
name = "Leon Kowarschick";
|
||||||
};
|
};
|
||||||
|
elnudev = {
|
||||||
|
email = "elnu@elnu.com";
|
||||||
|
github = "elnudev";
|
||||||
|
githubId = 9874955;
|
||||||
|
name = "Elnu";
|
||||||
|
};
|
||||||
elohmeier = {
|
elohmeier = {
|
||||||
email = "elo-nixos@nerdworks.de";
|
email = "elo-nixos@nerdworks.de";
|
||||||
github = "elohmeier";
|
github = "elohmeier";
|
||||||
|
@ -6160,6 +6172,12 @@
|
||||||
githubId = 4085046;
|
githubId = 4085046;
|
||||||
name = "Imuli";
|
name = "Imuli";
|
||||||
};
|
};
|
||||||
|
inclyc = {
|
||||||
|
email = "i@lyc.dev";
|
||||||
|
github = "inclyc";
|
||||||
|
githubId = 36667224;
|
||||||
|
name = "Yingchi Long";
|
||||||
|
};
|
||||||
ineol = {
|
ineol = {
|
||||||
email = "leo.stefanesco@gmail.com";
|
email = "leo.stefanesco@gmail.com";
|
||||||
github = "ineol";
|
github = "ineol";
|
||||||
|
@ -9954,6 +9972,12 @@
|
||||||
fingerprint = "7A10 AB8E 0BEC 566B 090C 9BE3 D812 6E55 9CE7 C35D";
|
fingerprint = "7A10 AB8E 0BEC 566B 090C 9BE3 D812 6E55 9CE7 C35D";
|
||||||
}];
|
}];
|
||||||
};
|
};
|
||||||
|
nat-418 = {
|
||||||
|
email = "93013864+nat-418@users.noreply.github.com";
|
||||||
|
github = "nat-418";
|
||||||
|
githubId = 93013864;
|
||||||
|
name = "nat-418";
|
||||||
|
};
|
||||||
nathanruiz = {
|
nathanruiz = {
|
||||||
email = "nathanruiz@protonmail.com";
|
email = "nathanruiz@protonmail.com";
|
||||||
github = "nathanruiz";
|
github = "nathanruiz";
|
||||||
|
@ -10764,6 +10788,12 @@
|
||||||
githubId = 15930073;
|
githubId = 15930073;
|
||||||
name = "Moritz Scheuren";
|
name = "Moritz Scheuren";
|
||||||
};
|
};
|
||||||
|
ovlach = {
|
||||||
|
email = "ondrej@vlach.xyz";
|
||||||
|
name = "Ondrej Vlach";
|
||||||
|
github = "ovlach";
|
||||||
|
githubId = 4405107;
|
||||||
|
};
|
||||||
ozkutuk = {
|
ozkutuk = {
|
||||||
email = "ozkutuk@protonmail.com";
|
email = "ozkutuk@protonmail.com";
|
||||||
github = "ozkutuk";
|
github = "ozkutuk";
|
||||||
|
|
|
@ -83,6 +83,14 @@
|
||||||
<link xlink:href="options.html#opt-networking.stevenblack.enable">networking.stevenblack</link>.
|
<link xlink:href="options.html#opt-networking.stevenblack.enable">networking.stevenblack</link>.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
<link xlink:href="https://github.com/slurdge/goeland">goeland</link>,
|
||||||
|
an alternative to rss2email written in golang with many
|
||||||
|
filters. Available as
|
||||||
|
<link linkend="opt-services.goeland.enable">services.goeland</link>.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
<link xlink:href="https://github.com/ellie/atuin">atuin</link>,
|
<link xlink:href="https://github.com/ellie/atuin">atuin</link>,
|
||||||
|
@ -138,6 +146,30 @@
|
||||||
instead.
|
instead.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
<literal>checkInputs</literal> have been renamed to
|
||||||
|
<literal>nativeCheckInputs</literal>, because they behave the
|
||||||
|
same as <literal>nativeBuildInputs</literal> when
|
||||||
|
<literal>doCheck</literal> is set.
|
||||||
|
<literal>checkInputs</literal> now denote a new type of
|
||||||
|
dependencies, added to <literal>buildInputs</literal> when
|
||||||
|
<literal>doCheck</literal> is set. As a rule of thumb,
|
||||||
|
<literal>nativeCheckInputs</literal> are tools on
|
||||||
|
<literal>$PATH</literal> used during the tests, and
|
||||||
|
<literal>checkInputs</literal> are libraries which are linked
|
||||||
|
to executables built as part of the tests. Similarly,
|
||||||
|
<literal>installCheckInputs</literal> are renamed to
|
||||||
|
<literal>nativeInstallCheckInputs</literal>, corresponding to
|
||||||
|
<literal>nativeBuildInputs</literal>, and
|
||||||
|
<literal>installCheckInputs</literal> are a new type of
|
||||||
|
dependencies added to <literal>buildInputs</literal> when
|
||||||
|
<literal>doInstallCheck</literal> is set. (Note that this
|
||||||
|
change will not cause breakage to derivations with
|
||||||
|
<literal>strictDeps</literal> unset, which are most packages
|
||||||
|
except python, rust and go packages).
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
<literal>borgbackup</literal> module now has an option for
|
<literal>borgbackup</literal> module now has an option for
|
||||||
|
@ -270,6 +302,16 @@
|
||||||
stage-2.
|
stage-2.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
<literal>teleport</literal> has been upgraded to major version
|
||||||
|
11. Please see upstream
|
||||||
|
<link xlink:href="https://goteleport.com/docs/setup/operations/upgrading/">upgrade
|
||||||
|
instructions</link> and
|
||||||
|
<link xlink:href="https://goteleport.com/docs/changelog/#1100">release
|
||||||
|
notes</link>.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
The EC2 image module previously detected and activated
|
The EC2 image module previously detected and activated
|
||||||
|
@ -414,6 +456,16 @@
|
||||||
which now also accepts structured settings.
|
which now also accepts structured settings.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
The <literal>wordpress</literal> service now takes
|
||||||
|
configuration via the
|
||||||
|
<literal>services.wordpress.sites.<name>.settings</literal>
|
||||||
|
attribute set, <literal>extraConfig</literal> is still
|
||||||
|
available to append additional text to
|
||||||
|
<literal>wp-config.php</literal>.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
To reduce closure size in
|
To reduce closure size in
|
||||||
|
@ -521,6 +573,22 @@
|
||||||
dynamically.
|
dynamically.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
The <literal>root</literal> package is now built with the
|
||||||
|
<literal>"-Dgnuinstall=ON"</literal> CMake flag,
|
||||||
|
making the output conform the <literal>bin</literal>
|
||||||
|
<literal>lib</literal> <literal>share</literal> layout. In
|
||||||
|
this layout, <literal>tutorials</literal> is under
|
||||||
|
<literal>share/doc/ROOT/</literal>; <literal>cmake</literal>,
|
||||||
|
<literal>font</literal>, <literal>icons</literal>,
|
||||||
|
<literal>js</literal> and <literal>macro</literal> under
|
||||||
|
<literal>share/root</literal>;
|
||||||
|
<literal>Makefile.comp</literal> and
|
||||||
|
<literal>Makefile.config</literal> under
|
||||||
|
<literal>etc/root</literal>.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
Enabling global redirect in
|
Enabling global redirect in
|
||||||
|
@ -616,6 +684,13 @@
|
||||||
information about the current generation revision
|
information about the current generation revision
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
The option
|
||||||
|
<literal>services.nomad.extraSettingsPlugins</literal> has
|
||||||
|
been fixed to allow more than one plugin in the path.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
</itemizedlist>
|
</itemizedlist>
|
||||||
</section>
|
</section>
|
||||||
</section>
|
</section>
|
||||||
|
|
|
@ -30,6 +30,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
|
|
||||||
- [stevenblack-blocklist](https://github.com/StevenBlack/hosts), A unified hosts file with base extensions for blocking unwanted websites. Available as [networking.stevenblack](options.html#opt-networking.stevenblack.enable).
|
- [stevenblack-blocklist](https://github.com/StevenBlack/hosts), A unified hosts file with base extensions for blocking unwanted websites. Available as [networking.stevenblack](options.html#opt-networking.stevenblack.enable).
|
||||||
|
|
||||||
|
- [goeland](https://github.com/slurdge/goeland), an alternative to rss2email written in golang with many filters. Available as [services.goeland](#opt-services.goeland.enable).
|
||||||
|
|
||||||
- [atuin](https://github.com/ellie/atuin), a sync server for shell history. Available as [services.atuin](#opt-services.atuin.enable).
|
- [atuin](https://github.com/ellie/atuin), a sync server for shell history. Available as [services.atuin](#opt-services.atuin.enable).
|
||||||
|
|
||||||
- [mmsd](https://gitlab.com/kop316/mmsd), a lower level daemon that transmits and recieves MMSes. Available as [services.mmsd](#opt-services.mmsd.enable).
|
- [mmsd](https://gitlab.com/kop316/mmsd), a lower level daemon that transmits and recieves MMSes. Available as [services.mmsd](#opt-services.mmsd.enable).
|
||||||
|
@ -46,6 +48,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
|
|
||||||
- `carnix` and `cratesIO` has been removed due to being unmaintained, use alternatives such as [naersk](https://github.com/nix-community/naersk) and [crate2nix](https://github.com/kolloch/crate2nix) instead.
|
- `carnix` and `cratesIO` has been removed due to being unmaintained, use alternatives such as [naersk](https://github.com/nix-community/naersk) and [crate2nix](https://github.com/kolloch/crate2nix) instead.
|
||||||
|
|
||||||
|
- `checkInputs` have been renamed to `nativeCheckInputs`, because they behave the same as `nativeBuildInputs` when `doCheck` is set. `checkInputs` now denote a new type of dependencies, added to `buildInputs` when `doCheck` is set. As a rule of thumb, `nativeCheckInputs` are tools on `$PATH` used during the tests, and `checkInputs` are libraries which are linked to executables built as part of the tests. Similarly, `installCheckInputs` are renamed to `nativeInstallCheckInputs`, corresponding to `nativeBuildInputs`, and `installCheckInputs` are a new type of dependencies added to `buildInputs` when `doInstallCheck` is set. (Note that this change will not cause breakage to derivations with `strictDeps` unset, which are most packages except python, rust and go packages).
|
||||||
|
|
||||||
- `borgbackup` module now has an option for inhibiting system sleep while backups are running, defaulting to off (not inhibiting sleep), available as [`services.borgbackup.jobs.<name>.inhibitsSleep`](#opt-services.borgbackup.jobs._name_.inhibitsSleep).
|
- `borgbackup` module now has an option for inhibiting system sleep while backups are running, defaulting to off (not inhibiting sleep), available as [`services.borgbackup.jobs.<name>.inhibitsSleep`](#opt-services.borgbackup.jobs._name_.inhibitsSleep).
|
||||||
|
|
||||||
- `podman` now uses the `netavark` network stack. Users will need to delete all of their local containers, images, volumes, etc, by running `podman system reset --force` once before upgrading their systems.
|
- `podman` now uses the `netavark` network stack. Users will need to delete all of their local containers, images, volumes, etc, by running `podman system reset --force` once before upgrading their systems.
|
||||||
|
@ -71,6 +75,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
|
|
||||||
- The EC2 image module previously detected and automatically mounted ext3-formatted instance store devices and partitions in stage-1 (initramfs), storing `/tmp` on the first discovered device. This behaviour, which only catered to very specific use cases and could not be disabled, has been removed. Users relying on this should provide their own implementation, and probably use ext4 and perform the mount in stage-2.
|
- The EC2 image module previously detected and automatically mounted ext3-formatted instance store devices and partitions in stage-1 (initramfs), storing `/tmp` on the first discovered device. This behaviour, which only catered to very specific use cases and could not be disabled, has been removed. Users relying on this should provide their own implementation, and probably use ext4 and perform the mount in stage-2.
|
||||||
|
|
||||||
|
- `teleport` has been upgraded to major version 11. Please see upstream [upgrade instructions](https://goteleport.com/docs/setup/operations/upgrading/) and [release notes](https://goteleport.com/docs/changelog/#1100).
|
||||||
|
|
||||||
- The EC2 image module previously detected and activated swap-formatted instance store devices and partitions in stage-1 (initramfs). This behaviour has been removed. Users relying on this should provide their own implementation.
|
- The EC2 image module previously detected and activated swap-formatted instance store devices and partitions in stage-1 (initramfs). This behaviour has been removed. Users relying on this should provide their own implementation.
|
||||||
|
|
||||||
- Calling `makeSetupHook` without passing a `name` argument is deprecated.
|
- Calling `makeSetupHook` without passing a `name` argument is deprecated.
|
||||||
|
@ -111,6 +117,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
The `{aclUse,superUser,disableActions}` attributes have been renamed, `pluginsConfig` now also accepts an attribute set of booleans, passing plain PHP is deprecated.
|
The `{aclUse,superUser,disableActions}` attributes have been renamed, `pluginsConfig` now also accepts an attribute set of booleans, passing plain PHP is deprecated.
|
||||||
Same applies to `acl` which now also accepts structured settings.
|
Same applies to `acl` which now also accepts structured settings.
|
||||||
|
|
||||||
|
- The `wordpress` service now takes configuration via the `services.wordpress.sites.<name>.settings` attribute set, `extraConfig` is still available to append additional text to `wp-config.php`.
|
||||||
|
|
||||||
- To reduce closure size in `nixos/modules/profiles/minimal.nix` profile disabled installation documentations and manuals. Also disabled `logrotate` and `udisks2` services.
|
- To reduce closure size in `nixos/modules/profiles/minimal.nix` profile disabled installation documentations and manuals. Also disabled `logrotate` and `udisks2` services.
|
||||||
|
|
||||||
- The minimal ISO image now uses the `nixos/modules/profiles/minimal.nix` profile.
|
- The minimal ISO image now uses the `nixos/modules/profiles/minimal.nix` profile.
|
||||||
|
@ -140,6 +148,8 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
|
|
||||||
- The new option `users.motdFile` allows configuring a Message Of The Day that can be updated dynamically.
|
- The new option `users.motdFile` allows configuring a Message Of The Day that can be updated dynamically.
|
||||||
|
|
||||||
|
- The `root` package is now built with the `"-Dgnuinstall=ON"` CMake flag, making the output conform the `bin` `lib` `share` layout. In this layout, `tutorials` is under `share/doc/ROOT/`; `cmake`, `font`, `icons`, `js` and `macro` under `share/root`; `Makefile.comp` and `Makefile.config` under `etc/root`.
|
||||||
|
|
||||||
- Enabling global redirect in `services.nginx.virtualHosts` now allows one to add exceptions with the `locations` option.
|
- Enabling global redirect in `services.nginx.virtualHosts` now allows one to add exceptions with the `locations` option.
|
||||||
|
|
||||||
- A new option `recommendedBrotliSettings` has been added to `services.nginx`. Learn more about compression in Brotli format [here](https://github.com/google/ngx_brotli/blob/master/README.md).
|
- A new option `recommendedBrotliSettings` has been added to `services.nginx`. Learn more about compression in Brotli format [here](https://github.com/google/ngx_brotli/blob/master/README.md).
|
||||||
|
@ -161,3 +171,5 @@ In addition to numerous new and upgraded packages, this release has the followin
|
||||||
- [Xastir](https://xastir.org/index.php/Main_Page) can now access AX.25 interfaces via the `libax25` package.
|
- [Xastir](https://xastir.org/index.php/Main_Page) can now access AX.25 interfaces via the `libax25` package.
|
||||||
|
|
||||||
- `nixos-version` now accepts `--configuration-revision` to display more information about the current generation revision
|
- `nixos-version` now accepts `--configuration-revision` to display more information about the current generation revision
|
||||||
|
|
||||||
|
- The option `services.nomad.extraSettingsPlugins` has been fixed to allow more than one plugin in the path.
|
||||||
|
|
|
@ -31,7 +31,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
++ extraPythonPackages python3Packages;
|
++ extraPythonPackages python3Packages;
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
checkInputs = with python3Packages; [ mypy pylint black ];
|
nativeCheckInputs = with python3Packages; [ mypy pylint black ];
|
||||||
checkPhase = ''
|
checkPhase = ''
|
||||||
mypy --disallow-untyped-defs \
|
mypy --disallow-untyped-defs \
|
||||||
--no-implicit-optional \
|
--no-implicit-optional \
|
||||||
|
|
|
@ -32,13 +32,17 @@ with lib;
|
||||||
dbus = super.dbus.override { x11Support = false; };
|
dbus = super.dbus.override { x11Support = false; };
|
||||||
ffmpeg_4 = super.ffmpeg_4-headless;
|
ffmpeg_4 = super.ffmpeg_4-headless;
|
||||||
ffmpeg_5 = super.ffmpeg_5-headless;
|
ffmpeg_5 = super.ffmpeg_5-headless;
|
||||||
|
# dep of graphviz, libXpm is optional for Xpm support
|
||||||
|
gd = super.gd.override { withXorg = false; };
|
||||||
gobject-introspection = super.gobject-introspection.override { x11Support = false; };
|
gobject-introspection = super.gobject-introspection.override { x11Support = false; };
|
||||||
|
gpsd = super.gpsd.override { guiSupport = false; };
|
||||||
|
graphviz = super.graphviz-nox;
|
||||||
gst_all_1 = super.gst_all_1 // {
|
gst_all_1 = super.gst_all_1 // {
|
||||||
gst-plugins-base = super.gst_all_1.gst-plugins-base.override { enableX11 = false; };
|
gst-plugins-base = super.gst_all_1.gst-plugins-base.override { enableX11 = false; };
|
||||||
};
|
};
|
||||||
gpsd = super.gpsd.override { guiSupport = false; };
|
|
||||||
imagemagick = super.imagemagick.override { libX11Support = false; libXtSupport = false; };
|
imagemagick = super.imagemagick.override { libX11Support = false; libXtSupport = false; };
|
||||||
imagemagickBig = super.imagemagickBig.override { libX11Support = false; libXtSupport = false; };
|
imagemagickBig = super.imagemagickBig.override { libX11Support = false; libXtSupport = false; };
|
||||||
|
libdevil = super.libdevil-nox;
|
||||||
libextractor = super.libextractor.override { gtkSupport = false; };
|
libextractor = super.libextractor.override { gtkSupport = false; };
|
||||||
libva = super.libva-minimal;
|
libva = super.libva-minimal;
|
||||||
limesuite = super.limesuite.override { withGui = false; };
|
limesuite = super.limesuite.override { withGui = false; };
|
||||||
|
@ -51,9 +55,13 @@ with lib;
|
||||||
networkmanager-openvpn = super.networkmanager-openvpn.override { withGnome = false; };
|
networkmanager-openvpn = super.networkmanager-openvpn.override { withGnome = false; };
|
||||||
networkmanager-sstp = super.networkmanager-vpnc.override { withGnome = false; };
|
networkmanager-sstp = super.networkmanager-vpnc.override { withGnome = false; };
|
||||||
networkmanager-vpnc = super.networkmanager-vpnc.override { withGnome = false; };
|
networkmanager-vpnc = super.networkmanager-vpnc.override { withGnome = false; };
|
||||||
|
pango = super.pango.override { x11Support = false; };
|
||||||
pinentry = super.pinentry.override { enabledFlavors = [ "curses" "tty" "emacs" ]; withLibsecret = false; };
|
pinentry = super.pinentry.override { enabledFlavors = [ "curses" "tty" "emacs" ]; withLibsecret = false; };
|
||||||
qemu = super.qemu.override { gtkSupport = false; spiceSupport = false; sdlSupport = false; };
|
qemu = super.qemu.override { gtkSupport = false; spiceSupport = false; sdlSupport = false; };
|
||||||
qrencode = super.qrencode.overrideAttrs (_: { doCheck = false; });
|
qrencode = super.qrencode.overrideAttrs (_: { doCheck = false; });
|
||||||
|
stoken = super.stoken.override { withGTK3 = false; };
|
||||||
|
# translateManpages -> perlPackages.po4a -> texlive-combined-basic -> texlive-core-big -> libX11
|
||||||
|
util-linux = super.util-linux.override { translateManpages = false; };
|
||||||
zbar = super.zbar.override { enableVideo = false; withXorg = false; };
|
zbar = super.zbar.override { enableVideo = false; withXorg = false; };
|
||||||
}));
|
}));
|
||||||
};
|
};
|
||||||
|
|
|
@ -66,7 +66,7 @@ let
|
||||||
|
|
||||||
device = mkOption {
|
device = mkOption {
|
||||||
example = "/dev/sda3";
|
example = "/dev/sda3";
|
||||||
type = types.str;
|
type = types.nonEmptyStr;
|
||||||
description = lib.mdDoc "Path of the device or swap file.";
|
description = lib.mdDoc "Path of the device or swap file.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -197,6 +197,21 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf ((length config.swapDevices) != 0) {
|
config = mkIf ((length config.swapDevices) != 0) {
|
||||||
|
assertions = map (sw: {
|
||||||
|
assertion = sw.randomEncryption.enable -> builtins.match "/dev/disk/by-(uuid|label)/.*" sw.device == null;
|
||||||
|
message = ''
|
||||||
|
You cannot use swap device "${sw.device}" with randomEncryption enabled.
|
||||||
|
The UUIDs and labels will get erased on every boot when the partition is encrypted.
|
||||||
|
Use /dev/disk/by-partuuid/… instead.
|
||||||
|
'';
|
||||||
|
}) config.swapDevices;
|
||||||
|
|
||||||
|
warnings =
|
||||||
|
concatMap (sw:
|
||||||
|
if sw.size != null && hasPrefix "/dev/" sw.device
|
||||||
|
then [ "Setting the swap size of block device ${sw.device} has no effect" ]
|
||||||
|
else [ ])
|
||||||
|
config.swapDevices;
|
||||||
|
|
||||||
system.requiredKernelConfig = with config.lib.kernelConfig; [
|
system.requiredKernelConfig = with config.lib.kernelConfig; [
|
||||||
(isYes "SWAP")
|
(isYes "SWAP")
|
||||||
|
@ -205,24 +220,27 @@ in
|
||||||
# Create missing swapfiles.
|
# Create missing swapfiles.
|
||||||
systemd.services =
|
systemd.services =
|
||||||
let
|
let
|
||||||
|
|
||||||
createSwapDevice = sw:
|
createSwapDevice = sw:
|
||||||
assert sw.device != "";
|
|
||||||
assert !(sw.randomEncryption.enable && lib.hasPrefix "/dev/disk/by-uuid" sw.device);
|
|
||||||
assert !(sw.randomEncryption.enable && lib.hasPrefix "/dev/disk/by-label" sw.device);
|
|
||||||
let realDevice' = escapeSystemdPath sw.realDevice;
|
let realDevice' = escapeSystemdPath sw.realDevice;
|
||||||
in nameValuePair "mkswap-${sw.deviceName}"
|
in nameValuePair "mkswap-${sw.deviceName}"
|
||||||
{ description = "Initialisation of swap device ${sw.device}";
|
{ description = "Initialisation of swap device ${sw.device}";
|
||||||
wantedBy = [ "${realDevice'}.swap" ];
|
wantedBy = [ "${realDevice'}.swap" ];
|
||||||
before = [ "${realDevice'}.swap" ];
|
before = [ "${realDevice'}.swap" ];
|
||||||
path = [ pkgs.util-linux ] ++ optional sw.randomEncryption.enable pkgs.cryptsetup;
|
path = [ pkgs.util-linux pkgs.e2fsprogs ]
|
||||||
|
++ optional sw.randomEncryption.enable pkgs.cryptsetup;
|
||||||
|
|
||||||
|
environment.DEVICE = sw.device;
|
||||||
|
|
||||||
script =
|
script =
|
||||||
''
|
''
|
||||||
${optionalString (sw.size != null) ''
|
${optionalString (sw.size != null) ''
|
||||||
currentSize=$(( $(stat -c "%s" "${sw.device}" 2>/dev/null || echo 0) / 1024 / 1024 ))
|
currentSize=$(( $(stat -c "%s" "$DEVICE" 2>/dev/null || echo 0) / 1024 / 1024 ))
|
||||||
if [ "${toString sw.size}" != "$currentSize" ]; then
|
if [[ ! -b "$DEVICE" && "${toString sw.size}" != "$currentSize" ]]; then
|
||||||
dd if=/dev/zero of="${sw.device}" bs=1M count=${toString sw.size}
|
# Disable CoW for CoW based filesystems like BTRFS.
|
||||||
|
truncate --size 0 "$DEVICE"
|
||||||
|
chattr +C "$DEVICE" 2>/dev/null || true
|
||||||
|
|
||||||
|
dd if=/dev/zero of="$DEVICE" bs=1M count=${toString sw.size}
|
||||||
chmod 0600 ${sw.device}
|
chmod 0600 ${sw.device}
|
||||||
${optionalString (!sw.randomEncryption.enable) "mkswap ${sw.realDevice}"}
|
${optionalString (!sw.randomEncryption.enable) "mkswap ${sw.realDevice}"}
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -14,6 +14,10 @@
|
||||||
|
|
||||||
documentation.man.enable = lib.mkOverride 500 true;
|
documentation.man.enable = lib.mkOverride 500 true;
|
||||||
|
|
||||||
|
# Although we don't really need HTML documentation in the minimal installer,
|
||||||
|
# not including it may cause annoying cache misses in the case of the NixOS manual.
|
||||||
|
documentation.doc.enable = lib.mkOverride 500 true;
|
||||||
|
|
||||||
fonts.fontconfig.enable = lib.mkForce false;
|
fonts.fontconfig.enable = lib.mkForce false;
|
||||||
|
|
||||||
isoImage.edition = lib.mkForce "minimal";
|
isoImage.edition = lib.mkForce "minimal";
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
x86_64-linux = "/nix/store/h88w1442c7hzkbw8sgpcsbqp4lhz6l5p-nix-2.12.0";
|
x86_64-linux = "/nix/store/vggs4ndlda1bhnldjrs4nm5a2walsnl6-nix-2.13.1";
|
||||||
i686-linux = "/nix/store/j23527l1c3hfx17nssc0v53sq6c741zs-nix-2.12.0";
|
i686-linux = "/nix/store/5g6w3p8l8k2mfghxrg48w7fcqbmr3c2p-nix-2.13.1";
|
||||||
aarch64-linux = "/nix/store/zgzmdymyh934y3r4vqh8z337ba4cwsjb-nix-2.12.0";
|
aarch64-linux = "/nix/store/pkbg60qv1w387c80g4xnb6w06461vw3i-nix-2.13.1";
|
||||||
x86_64-darwin = "/nix/store/wnlrzllazdyg1nrw9na497p4w0m7i7mm-nix-2.12.0";
|
x86_64-darwin = "/nix/store/jahjn6dvlw5kygqhg6da1b2ydcdak4lx-nix-2.13.1";
|
||||||
aarch64-darwin = "/nix/store/7n5yamgzg5dpp5vb6ipdqgfh6cf30wmn-nix-2.12.0";
|
aarch64-darwin = "/nix/store/2qalrx6py8r640wqsldmdf2zsaf8cpsg-nix-2.13.1";
|
||||||
}
|
}
|
||||||
|
|
15
nixos/modules/installer/tools/nixos-install.sh
Normal file → Executable file
15
nixos/modules/installer/tools/nixos-install.sh
Normal file → Executable file
|
@ -195,7 +195,20 @@ if [[ -z $noBootLoader ]]; then
|
||||||
echo "installing the boot loader..."
|
echo "installing the boot loader..."
|
||||||
# Grub needs an mtab.
|
# Grub needs an mtab.
|
||||||
ln -sfn /proc/mounts "$mountPoint"/etc/mtab
|
ln -sfn /proc/mounts "$mountPoint"/etc/mtab
|
||||||
NIXOS_INSTALL_BOOTLOADER=1 nixos-enter --root "$mountPoint" -- /run/current-system/bin/switch-to-configuration boot
|
export mountPoint
|
||||||
|
NIXOS_INSTALL_BOOTLOADER=1 nixos-enter --root "$mountPoint" -c "$(cat <<'EOF'
|
||||||
|
# Create a bind mount for each of the mount points inside the target file
|
||||||
|
# system. This preserves the validity of their absolute paths after changing
|
||||||
|
# the root with `nixos-enter`.
|
||||||
|
# Without this the bootloader installation may fail due to options that
|
||||||
|
# contain paths referenced during evaluation, like initrd.secrets.
|
||||||
|
# when not root, re-execute the script in an unshared namespace
|
||||||
|
mount --rbind --mkdir / "$mountPoint"
|
||||||
|
mount --make-rslave "$mountPoint"
|
||||||
|
/run/current-system/bin/switch-to-configuration boot
|
||||||
|
umount -R "$mountPoint" && rmdir "$mountPoint"
|
||||||
|
EOF
|
||||||
|
)"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Ask the user to set a root password, but only if the passwd command
|
# Ask the user to set a root password, but only if the passwd command
|
||||||
|
|
|
@ -235,6 +235,8 @@ in
|
||||||
nixos-enter
|
nixos-enter
|
||||||
] ++ lib.optional (nixos-option != null) nixos-option;
|
] ++ lib.optional (nixos-option != null) nixos-option;
|
||||||
|
|
||||||
|
documentation.man.man-db.skipPackages = [ nixos-version ];
|
||||||
|
|
||||||
system.build = {
|
system.build = {
|
||||||
inherit nixos-install nixos-generate-config nixos-option nixos-rebuild nixos-enter;
|
inherit nixos-install nixos-generate-config nixos-option nixos-rebuild nixos-enter;
|
||||||
};
|
};
|
||||||
|
|
|
@ -13,11 +13,21 @@ in
|
||||||
example = false;
|
example = false;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
skipPackages = lib.mkOption {
|
||||||
|
type = lib.types.listOf lib.types.package;
|
||||||
|
default = [];
|
||||||
|
internal = true;
|
||||||
|
description = lib.mdDoc ''
|
||||||
|
Packages to *not* include in the man-db.
|
||||||
|
This can be useful to avoid unnecessary rebuilds due to packages that change frequently, like nixos-version.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
manualPages = lib.mkOption {
|
manualPages = lib.mkOption {
|
||||||
type = lib.types.path;
|
type = lib.types.path;
|
||||||
default = pkgs.buildEnv {
|
default = pkgs.buildEnv {
|
||||||
name = "man-paths";
|
name = "man-paths";
|
||||||
paths = config.environment.systemPackages;
|
paths = lib.subtractLists cfg.skipPackages config.environment.systemPackages;
|
||||||
pathsToLink = [ "/share/man" ];
|
pathsToLink = [ "/share/man" ];
|
||||||
extraOutputsToInstall = [ "man" ]
|
extraOutputsToInstall = [ "man" ]
|
||||||
++ lib.optionals config.documentation.dev.enable [ "devman" ];
|
++ lib.optionals config.documentation.dev.enable [ "devman" ];
|
||||||
|
|
|
@ -530,6 +530,7 @@
|
||||||
./services/mail/dovecot.nix
|
./services/mail/dovecot.nix
|
||||||
./services/mail/dspam.nix
|
./services/mail/dspam.nix
|
||||||
./services/mail/exim.nix
|
./services/mail/exim.nix
|
||||||
|
./services/mail/goeland.nix
|
||||||
./services/mail/listmonk.nix
|
./services/mail/listmonk.nix
|
||||||
./services/mail/maddy.nix
|
./services/mail/maddy.nix
|
||||||
./services/mail/mail.nix
|
./services/mail/mail.nix
|
||||||
|
|
|
@ -35,6 +35,7 @@
|
||||||
pkgs.rsync
|
pkgs.rsync
|
||||||
pkgs.socat
|
pkgs.socat
|
||||||
pkgs.screen
|
pkgs.screen
|
||||||
|
pkgs.tcpdump
|
||||||
|
|
||||||
# Hardware-related tools.
|
# Hardware-related tools.
|
||||||
pkgs.sdparm
|
pkgs.sdparm
|
||||||
|
|
74
nixos/modules/services/mail/goeland.nix
Normal file
74
nixos/modules/services/mail/goeland.nix
Normal file
|
@ -0,0 +1,74 @@
|
||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
|
||||||
|
with lib;
|
||||||
|
|
||||||
|
let
|
||||||
|
cfg = config.services.goeland;
|
||||||
|
tomlFormat = pkgs.formats.toml { };
|
||||||
|
in
|
||||||
|
{
|
||||||
|
options.services.goeland = {
|
||||||
|
enable = mkEnableOption (mdDoc "goeland");
|
||||||
|
|
||||||
|
settings = mkOption {
|
||||||
|
description = mdDoc ''
|
||||||
|
Configuration of goeland.
|
||||||
|
See the [example config file](https://github.com/slurdge/goeland/blob/master/cmd/asset/config.default.toml) for the available options.
|
||||||
|
'';
|
||||||
|
default = { };
|
||||||
|
type = tomlFormat.type;
|
||||||
|
};
|
||||||
|
schedule = mkOption {
|
||||||
|
type = types.str;
|
||||||
|
default = "12h";
|
||||||
|
example = "Mon, 00:00:00";
|
||||||
|
description = mdDoc "How often to run goeland, in systemd time format.";
|
||||||
|
};
|
||||||
|
stateDir = mkOption {
|
||||||
|
type = types.path;
|
||||||
|
default = "/var/lib/goeland";
|
||||||
|
description = mdDoc ''
|
||||||
|
The data directory for goeland where the database will reside if using the unseen filter.
|
||||||
|
If left as the default value this directory will automatically be created before the goeland
|
||||||
|
server starts, otherwise you are responsible for ensuring the directory exists with
|
||||||
|
appropriate ownership and permissions.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
services.goeland.settings.database = "${cfg.stateDir}/goeland.db";
|
||||||
|
|
||||||
|
systemd.services.goeland = {
|
||||||
|
serviceConfig = let confFile = tomlFormat.generate "config.toml" cfg.settings; in mkMerge [
|
||||||
|
{
|
||||||
|
ExecStart = "${pkgs.goeland}/bin/goeland run -c ${confFile}";
|
||||||
|
User = "goeland";
|
||||||
|
Group = "goeland";
|
||||||
|
}
|
||||||
|
(mkIf (cfg.stateDir == "/var/lib/goeland") {
|
||||||
|
StateDirectory = "goeland";
|
||||||
|
StateDirectoryMode = "0750";
|
||||||
|
})
|
||||||
|
];
|
||||||
|
startAt = cfg.schedule;
|
||||||
|
};
|
||||||
|
|
||||||
|
users.users.goeland = {
|
||||||
|
description = "goeland user";
|
||||||
|
group = "goeland";
|
||||||
|
isSystemUser = true;
|
||||||
|
};
|
||||||
|
users.groups.goeland = { };
|
||||||
|
|
||||||
|
warnings = optionals (hasAttr "password" cfg.settings.email) [
|
||||||
|
''
|
||||||
|
It is not recommended to set the "services.goeland.settings.email.password"
|
||||||
|
option as it will be in cleartext in the Nix store.
|
||||||
|
Please use "services.goeland.settings.email.password_file" instead.
|
||||||
|
''
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
meta.maintainers = with maintainers; [ sweenu ];
|
||||||
|
}
|
|
@ -175,7 +175,7 @@ in
|
||||||
};
|
};
|
||||||
|
|
||||||
type = mkOption {
|
type = mkOption {
|
||||||
type = types.enum [ "zip" "rar" "tar" "sz" "tar.gz" "tar.xz" "tar.bz2" "tar.br" "tar.lz4" ];
|
type = types.enum [ "zip" "rar" "tar" "sz" "tar.gz" "tar.xz" "tar.bz2" "tar.br" "tar.lz4" "tar.zst" ];
|
||||||
default = "zip";
|
default = "zip";
|
||||||
description = lib.mdDoc "Archive format used to store the dump file.";
|
description = lib.mdDoc "Archive format used to store the dump file.";
|
||||||
};
|
};
|
||||||
|
|
|
@ -67,7 +67,7 @@ in
|
||||||
Additional plugins dir used to configure nomad.
|
Additional plugins dir used to configure nomad.
|
||||||
'';
|
'';
|
||||||
example = literalExpression ''
|
example = literalExpression ''
|
||||||
[ "<pluginDir>" pkgs.<plugins-name> ]
|
[ "<pluginDir>" pkgs.nomad-driver-nix pkgs.nomad-driver-podman ]
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -139,9 +139,16 @@ in
|
||||||
{
|
{
|
||||||
DynamicUser = cfg.dropPrivileges;
|
DynamicUser = cfg.dropPrivileges;
|
||||||
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
ExecReload = "${pkgs.coreutils}/bin/kill -HUP $MAINPID";
|
||||||
ExecStart = "${cfg.package}/bin/nomad agent -config=/etc/nomad.json" +
|
ExecStart =
|
||||||
concatMapStrings (path: " -config=${path}") cfg.extraSettingsPaths +
|
let
|
||||||
concatMapStrings (path: " -plugin-dir=${path}/bin") cfg.extraSettingsPlugins;
|
pluginsDir = pkgs.symlinkJoin
|
||||||
|
{
|
||||||
|
name = "nomad-plugins";
|
||||||
|
paths = cfg.extraSettingsPlugins;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
"${cfg.package}/bin/nomad agent -config=/etc/nomad.json -plugin-dir=${pluginsDir}/bin" +
|
||||||
|
concatMapStrings (path: " -config=${path}") cfg.extraSettingsPaths;
|
||||||
KillMode = "process";
|
KillMode = "process";
|
||||||
KillSignal = "SIGINT";
|
KillSignal = "SIGINT";
|
||||||
LimitNOFILE = 65536;
|
LimitNOFILE = 65536;
|
||||||
|
|
|
@ -73,28 +73,16 @@ let
|
||||||
${if isString pc then pc else pc_gen pc}
|
${if isString pc then pc else pc_gen pc}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
pkg = hostName: cfg: pkgs.stdenv.mkDerivation rec {
|
|
||||||
pname = "dokuwiki-${hostName}";
|
|
||||||
version = src.version;
|
|
||||||
src = cfg.package;
|
|
||||||
|
|
||||||
installPhase = ''
|
pkg = hostName: cfg: cfg.package.combine {
|
||||||
mkdir -p $out
|
inherit (cfg) plugins templates;
|
||||||
cp -r * $out/
|
|
||||||
|
|
||||||
# symlink the dokuwiki config
|
pname = p: "${p.pname}-${hostName}";
|
||||||
ln -sf ${dokuwikiLocalConfig hostName cfg} $out/share/dokuwiki/conf/local.php
|
|
||||||
|
|
||||||
# symlink plugins config
|
basePackage = cfg.package;
|
||||||
ln -sf ${dokuwikiPluginsLocalConfig hostName cfg} $out/share/dokuwiki/conf/plugins.local.php
|
localConfig = dokuwikiLocalConfig hostName cfg;
|
||||||
|
pluginsConfig = dokuwikiPluginsLocalConfig hostName cfg;
|
||||||
# symlink acl (if needed)
|
aclConfig = if cfg.aclUse && cfg.acl != null then dokuwikiAclAuthConfig hostName cfg else null;
|
||||||
${optionalString (cfg.mergedConfig.useacl && cfg.acl != null) "ln -sf ${dokuwikiAclAuthConfig hostName cfg} $out/share/dokuwiki/acl.auth.php"}
|
|
||||||
|
|
||||||
# symlink additional plugin(s) and templates(s)
|
|
||||||
${concatMapStringsSep "\n" (template: "ln -sf ${template} $out/share/dokuwiki/lib/tpl/${template.name}") cfg.templates}
|
|
||||||
${concatMapStringsSep "\n" (plugin: "ln -sf ${plugin} $out/share/dokuwiki/lib/plugins/${plugin.name}") cfg.plugins}
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
aclOpts = { ... }: {
|
aclOpts = { ... }: {
|
||||||
|
|
|
@ -113,7 +113,13 @@ in {
|
||||||
documentation = [ "https://docs.requarks.io/" ];
|
documentation = [ "https://docs.requarks.io/" ];
|
||||||
wantedBy = [ "multi-user.target" ];
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
|
||||||
path = with pkgs; [ coreutils ];
|
path = with pkgs; [
|
||||||
|
# Needed for git storage.
|
||||||
|
git
|
||||||
|
# Needed for git+ssh storage.
|
||||||
|
openssh
|
||||||
|
];
|
||||||
|
|
||||||
preStart = ''
|
preStart = ''
|
||||||
ln -sf ${configFile} /var/lib/${cfg.stateDirectoryName}/config.yml
|
ln -sf ${configFile} /var/lib/${cfg.stateDirectoryName}/config.yml
|
||||||
ln -sf ${pkgs.wiki-js}/server /var/lib/${cfg.stateDirectoryName}
|
ln -sf ${pkgs.wiki-js}/server /var/lib/${cfg.stateDirectoryName}
|
||||||
|
|
|
@ -38,22 +38,31 @@ let
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
wpConfig = hostName: cfg: pkgs.writeText "wp-config-${hostName}.php" ''
|
mergeConfig = cfg: {
|
||||||
|
# wordpress is installed onto a read-only file system
|
||||||
|
DISALLOW_FILE_EDIT = true;
|
||||||
|
AUTOMATIC_UPDATER_DISABLED = true;
|
||||||
|
DB_NAME = cfg.database.name;
|
||||||
|
DB_HOST = "${cfg.database.host}:${if cfg.database.socket != null then cfg.database.socket else toString cfg.database.port}";
|
||||||
|
DB_USER = cfg.database.user;
|
||||||
|
DB_CHARSET = "utf8";
|
||||||
|
# Always set DB_PASSWORD even when passwordFile is not set. This is the
|
||||||
|
# default Wordpress behaviour.
|
||||||
|
DB_PASSWORD = if (cfg.database.passwordFile != null) then { _file = cfg.database.passwordFile; } else "";
|
||||||
|
} // cfg.settings;
|
||||||
|
|
||||||
|
wpConfig = hostName: cfg: let
|
||||||
|
conf_gen = c: mapAttrsToList (k: v: "define('${k}', ${mkPhpValue v});") cfg.mergedConfig;
|
||||||
|
in pkgs.writeTextFile {
|
||||||
|
name = "wp-config-${hostName}.php";
|
||||||
|
text = ''
|
||||||
<?php
|
<?php
|
||||||
define('DB_NAME', '${cfg.database.name}');
|
|
||||||
define('DB_HOST', '${cfg.database.host}:${if cfg.database.socket != null then cfg.database.socket else toString cfg.database.port}');
|
|
||||||
define('DB_USER', '${cfg.database.user}');
|
|
||||||
${optionalString (cfg.database.passwordFile != null) "define('DB_PASSWORD', file_get_contents('${cfg.database.passwordFile}'));"}
|
|
||||||
define('DB_CHARSET', 'utf8');
|
|
||||||
$table_prefix = '${cfg.database.tablePrefix}';
|
$table_prefix = '${cfg.database.tablePrefix}';
|
||||||
|
|
||||||
require_once('${stateDir hostName}/secret-keys.php');
|
require_once('${stateDir hostName}/secret-keys.php');
|
||||||
|
|
||||||
# wordpress is installed onto a read-only file system
|
|
||||||
define('DISALLOW_FILE_EDIT', true);
|
|
||||||
define('AUTOMATIC_UPDATER_DISABLED', true);
|
|
||||||
|
|
||||||
${cfg.extraConfig}
|
${cfg.extraConfig}
|
||||||
|
${concatStringsSep "\n" (conf_gen cfg.mergedConfig)}
|
||||||
|
|
||||||
if ( !defined('ABSPATH') )
|
if ( !defined('ABSPATH') )
|
||||||
define('ABSPATH', dirname(__FILE__) . '/');
|
define('ABSPATH', dirname(__FILE__) . '/');
|
||||||
|
@ -61,6 +70,21 @@ let
|
||||||
require_once(ABSPATH . 'wp-settings.php');
|
require_once(ABSPATH . 'wp-settings.php');
|
||||||
?>
|
?>
|
||||||
'';
|
'';
|
||||||
|
checkPhase = "${pkgs.php81}/bin/php --syntax-check $target";
|
||||||
|
};
|
||||||
|
|
||||||
|
mkPhpValue = v: let
|
||||||
|
isHasAttr = s: isAttrs v && hasAttr s v;
|
||||||
|
in
|
||||||
|
if isString v then escapeShellArg v
|
||||||
|
# NOTE: If any value contains a , (comma) this will not get escaped
|
||||||
|
else if isList v && any lib.strings.isCoercibleToString v then escapeShellArg (concatMapStringsSep "," toString v)
|
||||||
|
else if isInt v then toString v
|
||||||
|
else if isBool v then boolToString v
|
||||||
|
else if isHasAttr "_file" then "trim(file_get_contents(${lib.escapeShellArg v._file}))"
|
||||||
|
else if isHasAttr "_raw" then v._raw
|
||||||
|
else abort "The Wordpress config value ${lib.generators.toPretty {} v} can not be encoded."
|
||||||
|
;
|
||||||
|
|
||||||
secretsVars = [ "AUTH_KEY" "SECURE_AUTH_KEY" "LOGGED_IN_KEY" "NONCE_KEY" "AUTH_SALT" "SECURE_AUTH_SALT" "LOGGED_IN_SALT" "NONCE_SALT" ];
|
secretsVars = [ "AUTH_KEY" "SECURE_AUTH_KEY" "LOGGED_IN_KEY" "NONCE_KEY" "AUTH_SALT" "SECURE_AUTH_SALT" "LOGGED_IN_SALT" "NONCE_SALT" ];
|
||||||
secretsScript = hostStateDir: ''
|
secretsScript = hostStateDir: ''
|
||||||
|
@ -77,7 +101,7 @@ let
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
|
|
||||||
siteOpts = { lib, name, ... }:
|
siteOpts = { lib, name, config, ... }:
|
||||||
{
|
{
|
||||||
options = {
|
options = {
|
||||||
package = mkOption {
|
package = mkOption {
|
||||||
|
@ -283,6 +307,42 @@ let
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
settings = mkOption {
|
||||||
|
type = types.attrsOf types.anything;
|
||||||
|
default = {};
|
||||||
|
description = lib.mdDoc ''
|
||||||
|
Structural Wordpress configuration.
|
||||||
|
Refer to <https://developer.wordpress.org/apis/wp-config-php>
|
||||||
|
for details and supported values.
|
||||||
|
'';
|
||||||
|
example = literalExpression ''
|
||||||
|
{
|
||||||
|
WP_DEFAULT_THEME = "twentytwentytwo";
|
||||||
|
WP_SITEURL = "https://example.org";
|
||||||
|
WP_HOME = "https://example.org";
|
||||||
|
WP_DEBUG = true;
|
||||||
|
WP_DEBUG_DISPLAY = true;
|
||||||
|
WPLANG = "de_DE";
|
||||||
|
FORCE_SSL_ADMIN = true;
|
||||||
|
AUTOMATIC_UPDATER_DISABLED = true;
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
mergedConfig = mkOption {
|
||||||
|
readOnly = true;
|
||||||
|
default = mergeConfig config;
|
||||||
|
defaultText = literalExpression ''
|
||||||
|
{
|
||||||
|
DISALLOW_FILE_EDIT = true;
|
||||||
|
AUTOMATIC_UPDATER_DISABLED = true;
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
description = lib.mdDoc ''
|
||||||
|
Read only representation of the final configuration.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
extraConfig = mkOption {
|
extraConfig = mkOption {
|
||||||
type = types.lines;
|
type = types.lines;
|
||||||
default = "";
|
default = "";
|
||||||
|
@ -290,11 +350,16 @@ let
|
||||||
Any additional text to be appended to the wp-config.php
|
Any additional text to be appended to the wp-config.php
|
||||||
configuration file. This is a PHP script. For configuration
|
configuration file. This is a PHP script. For configuration
|
||||||
settings, see <https://codex.wordpress.org/Editing_wp-config.php>.
|
settings, see <https://codex.wordpress.org/Editing_wp-config.php>.
|
||||||
|
|
||||||
|
**Note**: Please pass structured settings via
|
||||||
|
`services.wordpress.sites.${name}.settings` instead.
|
||||||
'';
|
'';
|
||||||
example = ''
|
example = ''
|
||||||
define( 'AUTOSAVE_INTERVAL', 60 ); // Seconds
|
@ini_set( 'log_errors', 'Off' );
|
||||||
|
@ini_set( 'display_errors', 'On' );
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
config.virtualHost.hostName = mkDefault name;
|
config.virtualHost.hostName = mkDefault name;
|
||||||
|
|
|
@ -401,7 +401,18 @@ in
|
||||||
|
|
||||||
environment.etc."X11/xkb".source = xcfg.xkbDir;
|
environment.etc."X11/xkb".source = xcfg.xkbDir;
|
||||||
|
|
||||||
environment.sessionVariables.PLASMA_USE_QT_SCALING = mkIf cfg.useQtScaling "1";
|
environment.sessionVariables = {
|
||||||
|
PLASMA_USE_QT_SCALING = mkIf cfg.useQtScaling "1";
|
||||||
|
|
||||||
|
# Needed for things that depend on other store.kde.org packages to install correctly,
|
||||||
|
# notably Plasma look-and-feel packages (a.k.a. Global Themes)
|
||||||
|
#
|
||||||
|
# FIXME: this is annoyingly impure and should really be fixed at source level somehow,
|
||||||
|
# but kpackage is a library so we can't just wrap the one thing invoking it and be done.
|
||||||
|
# This also means things won't work for people not on Plasma, but at least this way it
|
||||||
|
# works for SOME people.
|
||||||
|
KPACKAGE_DEP_RESOLVERS_PATH = "${pkgs.plasma5Packages.frameworkintegration.out}/libexec/kf5/kpackagehandlers";
|
||||||
|
};
|
||||||
|
|
||||||
# Enable GTK applications to load SVG icons
|
# Enable GTK applications to load SVG icons
|
||||||
services.xserver.gdk-pixbuf.modulePackages = [ pkgs.librsvg ];
|
services.xserver.gdk-pixbuf.modulePackages = [ pkgs.librsvg ];
|
||||||
|
|
|
@ -442,7 +442,7 @@ sub copyToKernelsDir {
|
||||||
}
|
}
|
||||||
|
|
||||||
sub addEntry {
|
sub addEntry {
|
||||||
my ($name, $path, $options) = @_;
|
my ($name, $path, $options, $current) = @_;
|
||||||
return unless -e "$path/kernel" && -e "$path/initrd";
|
return unless -e "$path/kernel" && -e "$path/initrd";
|
||||||
|
|
||||||
my $kernel = copyToKernelsDir(Cwd::abs_path("$path/kernel"));
|
my $kernel = copyToKernelsDir(Cwd::abs_path("$path/kernel"));
|
||||||
|
@ -458,7 +458,14 @@ sub addEntry {
|
||||||
# Make sure initrd is not world readable (won't work if /boot is FAT)
|
# Make sure initrd is not world readable (won't work if /boot is FAT)
|
||||||
umask 0137;
|
umask 0137;
|
||||||
my $initrdSecretsPathTemp = File::Temp::mktemp("$initrdSecretsPath.XXXXXXXX");
|
my $initrdSecretsPathTemp = File::Temp::mktemp("$initrdSecretsPath.XXXXXXXX");
|
||||||
system("$path/append-initrd-secrets", $initrdSecretsPathTemp) == 0 or die "failed to create initrd secrets: $!\n";
|
if (system("$path/append-initrd-secrets", $initrdSecretsPathTemp) != 0) {
|
||||||
|
if ($current) {
|
||||||
|
die "failed to create initrd secrets $!\n";
|
||||||
|
} else {
|
||||||
|
say STDERR "warning: failed to create initrd secrets for \"$name\", an older generation";
|
||||||
|
say STDERR "note: this is normal after having removed or renamed a file in `boot.initrd.secrets`";
|
||||||
|
}
|
||||||
|
}
|
||||||
# Check whether any secrets were actually added
|
# Check whether any secrets were actually added
|
||||||
if (-e $initrdSecretsPathTemp && ! -z _) {
|
if (-e $initrdSecretsPathTemp && ! -z _) {
|
||||||
rename $initrdSecretsPathTemp, $initrdSecretsPath or die "failed to move initrd secrets into place: $!\n";
|
rename $initrdSecretsPathTemp, $initrdSecretsPath or die "failed to move initrd secrets into place: $!\n";
|
||||||
|
@ -491,7 +498,7 @@ sub addEntry {
|
||||||
}
|
}
|
||||||
$conf .= "\n";
|
$conf .= "\n";
|
||||||
} else {
|
} else {
|
||||||
$conf .= "menuentry \"$name\" " . ($options||"") . " {\n";
|
$conf .= "menuentry \"$name\" " . $options . " {\n";
|
||||||
if ($saveDefault) {
|
if ($saveDefault) {
|
||||||
$conf .= " savedefault\n";
|
$conf .= " savedefault\n";
|
||||||
}
|
}
|
||||||
|
@ -511,7 +518,7 @@ sub addEntry {
|
||||||
# Add default entries.
|
# Add default entries.
|
||||||
$conf .= "$extraEntries\n" if $extraEntriesBeforeNixOS;
|
$conf .= "$extraEntries\n" if $extraEntriesBeforeNixOS;
|
||||||
|
|
||||||
addEntry("@distroName@ - Default", $defaultConfig, $entryOptions);
|
addEntry("@distroName@ - Default", $defaultConfig, $entryOptions, 1);
|
||||||
|
|
||||||
$conf .= "$extraEntries\n" unless $extraEntriesBeforeNixOS;
|
$conf .= "$extraEntries\n" unless $extraEntriesBeforeNixOS;
|
||||||
|
|
||||||
|
@ -536,7 +543,7 @@ foreach my $link (@links) {
|
||||||
my $linkname = basename($link);
|
my $linkname = basename($link);
|
||||||
$entryName = "($linkname - $date - $version)";
|
$entryName = "($linkname - $date - $version)";
|
||||||
}
|
}
|
||||||
addEntry("@distroName@ - $entryName", $link);
|
addEntry("@distroName@ - $entryName", $link, "", 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
my $grubBootPath = $grubBoot->path;
|
my $grubBootPath = $grubBoot->path;
|
||||||
|
@ -568,7 +575,7 @@ sub addProfile {
|
||||||
-e "$link/nixos-version"
|
-e "$link/nixos-version"
|
||||||
? readFile("$link/nixos-version")
|
? readFile("$link/nixos-version")
|
||||||
: basename((glob(dirname(Cwd::abs_path("$link/kernel")) . "/lib/modules/*"))[0]);
|
: basename((glob(dirname(Cwd::abs_path("$link/kernel")) . "/lib/modules/*"))[0]);
|
||||||
addEntry("@distroName@ - Configuration " . nrFromGen($link) . " ($date - $version)", $link, $subEntryOptions);
|
addEntry("@distroName@ - Configuration " . nrFromGen($link) . " ($date - $version)", $link, $subEntryOptions, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
$conf .= "}\n" if $grubVersion == 2;
|
$conf .= "}\n" if $grubVersion == 2;
|
||||||
|
|
|
@ -8,7 +8,7 @@ let
|
||||||
src = ./init-script-builder.sh;
|
src = ./init-script-builder.sh;
|
||||||
isExecutable = true;
|
isExecutable = true;
|
||||||
inherit (pkgs) bash;
|
inherit (pkgs) bash;
|
||||||
inherit (config.nixos.system) distroName;
|
inherit (config.system.nixos) distroName;
|
||||||
path = [pkgs.coreutils pkgs.gnused pkgs.gnugrep];
|
path = [pkgs.coreutils pkgs.gnused pkgs.gnugrep];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -42,7 +42,7 @@ def system_dir(profile: Optional[str], generation: int, specialisation: Optional
|
||||||
else:
|
else:
|
||||||
return d
|
return d
|
||||||
|
|
||||||
BOOT_ENTRY = """title @distroName@{profile}{specialisation}
|
BOOT_ENTRY = """title {title}
|
||||||
version Generation {generation} {description}
|
version Generation {generation} {description}
|
||||||
linux {kernel}
|
linux {kernel}
|
||||||
initrd {initrd}
|
initrd {initrd}
|
||||||
|
@ -106,14 +106,29 @@ def describe_generation(generation_dir: str) -> str:
|
||||||
return description
|
return description
|
||||||
|
|
||||||
|
|
||||||
def write_entry(profile: Optional[str], generation: int, specialisation: Optional[str], machine_id: str) -> None:
|
def write_entry(profile: Optional[str], generation: int, specialisation: Optional[str],
|
||||||
|
machine_id: str, current: bool) -> None:
|
||||||
kernel = copy_from_profile(profile, generation, specialisation, "kernel")
|
kernel = copy_from_profile(profile, generation, specialisation, "kernel")
|
||||||
initrd = copy_from_profile(profile, generation, specialisation, "initrd")
|
initrd = copy_from_profile(profile, generation, specialisation, "initrd")
|
||||||
|
|
||||||
|
title = "@distroName@{profile}{specialisation}".format(
|
||||||
|
profile=" [" + profile + "]" if profile else "",
|
||||||
|
specialisation=" (%s)" % specialisation if specialisation else "")
|
||||||
|
|
||||||
try:
|
try:
|
||||||
append_initrd_secrets = profile_path(profile, generation, specialisation, "append-initrd-secrets")
|
append_initrd_secrets = profile_path(profile, generation, specialisation, "append-initrd-secrets")
|
||||||
subprocess.check_call([append_initrd_secrets, "@efiSysMountPoint@%s" % (initrd)])
|
subprocess.check_call([append_initrd_secrets, "@efiSysMountPoint@%s" % (initrd)])
|
||||||
except FileNotFoundError:
|
except FileNotFoundError:
|
||||||
pass
|
pass
|
||||||
|
except subprocess.CalledProcessError:
|
||||||
|
if current:
|
||||||
|
print("failed to create initrd secrets!", file=sys.stderr)
|
||||||
|
sys.exit(1)
|
||||||
|
else:
|
||||||
|
print("warning: failed to create initrd secrets "
|
||||||
|
f'for "{title} - Configuration {generation}", an older generation', file=sys.stderr)
|
||||||
|
print("note: this is normal after having removed "
|
||||||
|
"or renamed a file in `boot.initrd.secrets`", file=sys.stderr)
|
||||||
entry_file = "@efiSysMountPoint@/loader/entries/%s" % (
|
entry_file = "@efiSysMountPoint@/loader/entries/%s" % (
|
||||||
generation_conf_filename(profile, generation, specialisation))
|
generation_conf_filename(profile, generation, specialisation))
|
||||||
generation_dir = os.readlink(system_dir(profile, generation, specialisation))
|
generation_dir = os.readlink(system_dir(profile, generation, specialisation))
|
||||||
|
@ -123,8 +138,7 @@ def write_entry(profile: Optional[str], generation: int, specialisation: Optiona
|
||||||
with open("%s/kernel-params" % (generation_dir)) as params_file:
|
with open("%s/kernel-params" % (generation_dir)) as params_file:
|
||||||
kernel_params = kernel_params + params_file.read()
|
kernel_params = kernel_params + params_file.read()
|
||||||
with open(tmp_path, 'w') as f:
|
with open(tmp_path, 'w') as f:
|
||||||
f.write(BOOT_ENTRY.format(profile=" [" + profile + "]" if profile else "",
|
f.write(BOOT_ENTRY.format(title=title,
|
||||||
specialisation=" (%s)" % specialisation if specialisation else "",
|
|
||||||
generation=generation,
|
generation=generation,
|
||||||
kernel=kernel,
|
kernel=kernel,
|
||||||
initrd=initrd,
|
initrd=initrd,
|
||||||
|
@ -281,10 +295,11 @@ def main() -> None:
|
||||||
remove_old_entries(gens)
|
remove_old_entries(gens)
|
||||||
for gen in gens:
|
for gen in gens:
|
||||||
try:
|
try:
|
||||||
write_entry(*gen, machine_id)
|
is_default = os.readlink(system_dir(*gen)) == args.default_config
|
||||||
|
write_entry(*gen, machine_id, current=is_default)
|
||||||
for specialisation in get_specialisations(*gen):
|
for specialisation in get_specialisations(*gen):
|
||||||
write_entry(*specialisation, machine_id)
|
write_entry(*specialisation, machine_id, current=is_default)
|
||||||
if os.readlink(system_dir(*gen)) == args.default_config:
|
if is_default:
|
||||||
write_loader_conf(*gen)
|
write_loader_conf(*gen)
|
||||||
except OSError as e:
|
except OSError as e:
|
||||||
profile = f"profile '{gen.profile}'" if gen.profile else "default profile"
|
profile = f"profile '{gen.profile}'" if gen.profile else "default profile"
|
||||||
|
|
|
@ -39,6 +39,20 @@ let
|
||||||
"timers.target"
|
"timers.target"
|
||||||
"xdg-desktop-autostart.target"
|
"xdg-desktop-autostart.target"
|
||||||
] ++ config.systemd.additionalUpstreamUserUnits;
|
] ++ config.systemd.additionalUpstreamUserUnits;
|
||||||
|
|
||||||
|
writeTmpfiles = { rules, user ? null }:
|
||||||
|
let
|
||||||
|
suffix = if user == null then "" else "-${user}";
|
||||||
|
in
|
||||||
|
pkgs.writeTextFile {
|
||||||
|
name = "nixos-user-tmpfiles.d${suffix}";
|
||||||
|
destination = "/etc/xdg/user-tmpfiles.d/00-nixos${suffix}.conf";
|
||||||
|
text = ''
|
||||||
|
# This file is created automatically and should not be modified.
|
||||||
|
# Please change the options ‘systemd.user.tmpfiles’ instead.
|
||||||
|
${concatStringsSep "\n" rules}
|
||||||
|
'';
|
||||||
|
};
|
||||||
in {
|
in {
|
||||||
options = {
|
options = {
|
||||||
systemd.user.extraConfig = mkOption {
|
systemd.user.extraConfig = mkOption {
|
||||||
|
@ -93,6 +107,43 @@ in {
|
||||||
description = lib.mdDoc "Definition of systemd per-user timer units.";
|
description = lib.mdDoc "Definition of systemd per-user timer units.";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
systemd.user.tmpfiles = {
|
||||||
|
rules = mkOption {
|
||||||
|
type = types.listOf types.str;
|
||||||
|
default = [];
|
||||||
|
example = [ "D %C - - - 7d" ];
|
||||||
|
description = lib.mdDoc ''
|
||||||
|
Global user rules for creation, deletion and cleaning of volatile and
|
||||||
|
temporary files automatically. See
|
||||||
|
{manpage}`tmpfiles.d(5)`
|
||||||
|
for the exact format.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
users = mkOption {
|
||||||
|
description = mdDoc ''
|
||||||
|
Per-user rules for creation, deletion and cleaning of volatile and
|
||||||
|
temporary files automatically.
|
||||||
|
'';
|
||||||
|
default = {};
|
||||||
|
type = types.attrsOf (types.submodule {
|
||||||
|
options = {
|
||||||
|
rules = mkOption {
|
||||||
|
type = types.listOf types.str;
|
||||||
|
default = [];
|
||||||
|
example = [ "D %C - - - 7d" ];
|
||||||
|
description = mdDoc ''
|
||||||
|
Per-user rules for creation, deletion and cleaning of volatile and
|
||||||
|
temporary files automatically. See
|
||||||
|
{manpage}`tmpfiles.d(5)`
|
||||||
|
for the exact format.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
});
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
systemd.additionalUpstreamUserUnits = mkOption {
|
systemd.additionalUpstreamUserUnits = mkOption {
|
||||||
default = [];
|
default = [];
|
||||||
type = types.listOf types.str;
|
type = types.listOf types.str;
|
||||||
|
@ -154,5 +205,30 @@ in {
|
||||||
# Some overrides to upstream units.
|
# Some overrides to upstream units.
|
||||||
systemd.services."user@".restartIfChanged = false;
|
systemd.services."user@".restartIfChanged = false;
|
||||||
systemd.services.systemd-user-sessions.restartIfChanged = false; # Restart kills all active sessions.
|
systemd.services.systemd-user-sessions.restartIfChanged = false; # Restart kills all active sessions.
|
||||||
|
|
||||||
|
# enable systemd user tmpfiles
|
||||||
|
systemd.user.services.systemd-tmpfiles-setup.wantedBy =
|
||||||
|
optional
|
||||||
|
(cfg.tmpfiles.rules != [] || any (cfg': cfg'.rules != []) (attrValues cfg.tmpfiles.users))
|
||||||
|
"basic.target";
|
||||||
|
|
||||||
|
# /run/current-system/sw/etc/xdg is in systemd's $XDG_CONFIG_DIRS so we can
|
||||||
|
# write the tmpfiles.d rules for everyone there
|
||||||
|
environment.systemPackages =
|
||||||
|
optional
|
||||||
|
(cfg.tmpfiles.rules != [])
|
||||||
|
(writeTmpfiles { inherit (cfg.tmpfiles) rules; });
|
||||||
|
|
||||||
|
# /etc/profiles/per-user/$USER/etc/xdg is in systemd's $XDG_CONFIG_DIRS so
|
||||||
|
# we can write a single user's tmpfiles.d rules there
|
||||||
|
users.users =
|
||||||
|
mapAttrs
|
||||||
|
(user: cfg': {
|
||||||
|
packages = optional (cfg'.rules != []) (writeTmpfiles {
|
||||||
|
inherit (cfg') rules;
|
||||||
|
inherit user;
|
||||||
|
});
|
||||||
|
})
|
||||||
|
cfg.tmpfiles.users;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -230,7 +230,10 @@ let
|
||||||
escapedName = escapeShellArg name;
|
escapedName = escapeShellArg name;
|
||||||
in {
|
in {
|
||||||
wantedBy = [] ++ optional (container.autoStart) "multi-user.target";
|
wantedBy = [] ++ optional (container.autoStart) "multi-user.target";
|
||||||
after = lib.optionals (cfg.backend == "docker") [ "docker.service" "docker.socket" ] ++ dependsOn;
|
after = lib.optionals (cfg.backend == "docker") [ "docker.service" "docker.socket" ]
|
||||||
|
# if imageFile is not set, the service needs the network to download the image from the registry
|
||||||
|
++ lib.optionals (container.imageFile == null) [ "network-online.target" ]
|
||||||
|
++ dependsOn;
|
||||||
requires = dependsOn;
|
requires = dependsOn;
|
||||||
environment = proxy_env;
|
environment = proxy_env;
|
||||||
|
|
||||||
|
|
|
@ -619,6 +619,7 @@ in {
|
||||||
strongswan-swanctl = handleTest ./strongswan-swanctl.nix {};
|
strongswan-swanctl = handleTest ./strongswan-swanctl.nix {};
|
||||||
stunnel = handleTest ./stunnel.nix {};
|
stunnel = handleTest ./stunnel.nix {};
|
||||||
sudo = handleTest ./sudo.nix {};
|
sudo = handleTest ./sudo.nix {};
|
||||||
|
swap-file-btrfs = handleTest ./swap-file-btrfs.nix {};
|
||||||
swap-partition = handleTest ./swap-partition.nix {};
|
swap-partition = handleTest ./swap-partition.nix {};
|
||||||
sway = handleTest ./sway.nix {};
|
sway = handleTest ./sway.nix {};
|
||||||
switchTest = handleTest ./switch-test.nix {};
|
switchTest = handleTest ./switch-test.nix {};
|
||||||
|
@ -657,6 +658,7 @@ in {
|
||||||
systemd-portabled = handleTest ./systemd-portabled.nix {};
|
systemd-portabled = handleTest ./systemd-portabled.nix {};
|
||||||
systemd-shutdown = handleTest ./systemd-shutdown.nix {};
|
systemd-shutdown = handleTest ./systemd-shutdown.nix {};
|
||||||
systemd-timesyncd = handleTest ./systemd-timesyncd.nix {};
|
systemd-timesyncd = handleTest ./systemd-timesyncd.nix {};
|
||||||
|
systemd-user-tmpfiles-rules = handleTest ./systemd-user-tmpfiles-rules.nix {};
|
||||||
systemd-misc = handleTest ./systemd-misc.nix {};
|
systemd-misc = handleTest ./systemd-misc.nix {};
|
||||||
systemd-userdbd = handleTest ./systemd-userdbd.nix {};
|
systemd-userdbd = handleTest ./systemd-userdbd.nix {};
|
||||||
systemd-homed = handleTest ./systemd-homed.nix {};
|
systemd-homed = handleTest ./systemd-homed.nix {};
|
||||||
|
|
|
@ -181,6 +181,17 @@ let
|
||||||
monA.wait_until_succeeds("ceph osd stat | grep -e '3 osds: 3 up[^,]*, 3 in'")
|
monA.wait_until_succeeds("ceph osd stat | grep -e '3 osds: 3 up[^,]*, 3 in'")
|
||||||
monA.wait_until_succeeds("ceph -s | grep 'mgr: ${cfg.monA.name}(active,'")
|
monA.wait_until_succeeds("ceph -s | grep 'mgr: ${cfg.monA.name}(active,'")
|
||||||
monA.wait_until_succeeds("ceph -s | grep 'HEALTH_OK'")
|
monA.wait_until_succeeds("ceph -s | grep 'HEALTH_OK'")
|
||||||
|
|
||||||
|
# Enable the dashboard and recheck health
|
||||||
|
monA.succeed(
|
||||||
|
"ceph mgr module enable dashboard",
|
||||||
|
"ceph config set mgr mgr/dashboard/ssl false",
|
||||||
|
# default is 8080 but it's better to be explicit
|
||||||
|
"ceph config set mgr mgr/dashboard/server_port 8080",
|
||||||
|
)
|
||||||
|
monA.wait_for_open_port(8080)
|
||||||
|
monA.wait_until_succeeds("curl -q --fail http://localhost:8080")
|
||||||
|
monA.wait_until_succeeds("ceph -s | grep 'HEALTH_OK'")
|
||||||
'';
|
'';
|
||||||
in {
|
in {
|
||||||
name = "basic-single-node-ceph-cluster";
|
name = "basic-single-node-ceph-cluster";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import ./make-test-python.nix ({ ... }: {
|
import ./make-test-python.nix ({ pkgs, ... }: {
|
||||||
name = "coturn";
|
name = "coturn";
|
||||||
nodes = {
|
nodes = {
|
||||||
default = {
|
default = {
|
||||||
|
@ -25,5 +25,9 @@ import ./make-test-python.nix ({ ... }: {
|
||||||
with subtest("works with static-auth-secret-file"):
|
with subtest("works with static-auth-secret-file"):
|
||||||
secretsfile.wait_for_unit("coturn.service")
|
secretsfile.wait_for_unit("coturn.service")
|
||||||
secretsfile.succeed("grep 'some-very-secret-string' /run/coturn/turnserver.cfg")
|
secretsfile.succeed("grep 'some-very-secret-string' /run/coturn/turnserver.cfg")
|
||||||
|
# Forbidden IP, fails:
|
||||||
|
secretsfile.fail("${pkgs.coturn}/bin/turnutils_uclient -W some-very-secret-string 127.0.0.1 -DgX -e 127.0.0.1 -n 1 -c -y")
|
||||||
|
# allowed-peer-ip, should succeed:
|
||||||
|
secretsfile.succeed("${pkgs.coturn}/bin/turnutils_uclient -W some-very-secret-string 192.168.1.2 -DgX -e 192.168.1.2 -n 1 -c -y")
|
||||||
'';
|
'';
|
||||||
})
|
})
|
||||||
|
|
|
@ -143,6 +143,14 @@ in {
|
||||||
"curl -sSfL 'http://site2.local/doku.php?id=plugin-list' | (! grep 'plugin:tag')",
|
"curl -sSfL 'http://site2.local/doku.php?id=plugin-list' | (! grep 'plugin:tag')",
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Test if theme is applied and working correctly (no weired relative PHP import errors)
|
||||||
|
machine.succeed(
|
||||||
|
"curl -sSfL 'http://site1.local/doku.php' | grep 'bootstrap3/images/logo.png'",
|
||||||
|
"curl -sSfL 'http://site1.local/lib/exe/css.php' | grep 'bootstrap3'",
|
||||||
|
"curl -sSfL 'http://site1.local/lib/tpl/bootstrap3/css.php'",
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
# Just to ensure both Webserver configurations are consistent in allowing that
|
# Just to ensure both Webserver configurations are consistent in allowing that
|
||||||
with subtest("Rewriting"):
|
with subtest("Rewriting"):
|
||||||
machine.succeed(
|
machine.succeed(
|
||||||
|
|
|
@ -51,7 +51,7 @@ let
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
''}
|
''}
|
||||||
|
|
||||||
boot.initrd.secrets."/etc/secret" = /etc/nixos/secret;
|
boot.initrd.secrets."/etc/secret" = ./secret;
|
||||||
|
|
||||||
users.users.alice = {
|
users.users.alice = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
|
@ -150,8 +150,7 @@ let
|
||||||
)
|
)
|
||||||
|
|
||||||
with subtest("Shutdown system after installation"):
|
with subtest("Shutdown system after installation"):
|
||||||
machine.succeed("umount /mnt/boot || true")
|
machine.succeed("umount -R /mnt")
|
||||||
machine.succeed("umount /mnt")
|
|
||||||
machine.succeed("sync")
|
machine.succeed("sync")
|
||||||
machine.shutdown()
|
machine.shutdown()
|
||||||
|
|
||||||
|
@ -309,7 +308,7 @@ let
|
||||||
# builds stuff in the VM, needs more juice
|
# builds stuff in the VM, needs more juice
|
||||||
virtualisation.diskSize = 8 * 1024;
|
virtualisation.diskSize = 8 * 1024;
|
||||||
virtualisation.cores = 8;
|
virtualisation.cores = 8;
|
||||||
virtualisation.memorySize = 2047;
|
virtualisation.memorySize = 1536;
|
||||||
|
|
||||||
boot.initrd.systemd.enable = systemdStage1;
|
boot.initrd.systemd.enable = systemdStage1;
|
||||||
|
|
||||||
|
@ -672,6 +671,55 @@ in {
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Full disk encryption (root, kernel and initrd encrypted) using GRUB, GPT/UEFI,
|
||||||
|
# LVM-on-LUKS and a keyfile in initrd.secrets to enter the passphrase once
|
||||||
|
fullDiskEncryption = makeInstallerTest "fullDiskEncryption" {
|
||||||
|
createPartitions = ''
|
||||||
|
machine.succeed(
|
||||||
|
"flock /dev/vda parted --script /dev/vda -- mklabel gpt"
|
||||||
|
+ " mkpart ESP fat32 1M 100MiB" # /boot/efi
|
||||||
|
+ " set 1 boot on"
|
||||||
|
+ " mkpart primary ext2 1024MiB -1MiB", # LUKS
|
||||||
|
"udevadm settle",
|
||||||
|
"modprobe dm_mod dm_crypt",
|
||||||
|
"dd if=/dev/random of=luks.key bs=256 count=1",
|
||||||
|
"echo -n supersecret | cryptsetup luksFormat -q --pbkdf-force-iterations 1000 --type luks1 /dev/vda2 -",
|
||||||
|
"echo -n supersecret | cryptsetup luksAddKey -q --pbkdf-force-iterations 1000 --key-file - /dev/vda2 luks.key",
|
||||||
|
"echo -n supersecret | cryptsetup luksOpen --key-file - /dev/vda2 crypt",
|
||||||
|
"pvcreate /dev/mapper/crypt",
|
||||||
|
"vgcreate crypt /dev/mapper/crypt",
|
||||||
|
"lvcreate -L 100M -n swap crypt",
|
||||||
|
"lvcreate -l '100%FREE' -n nixos crypt",
|
||||||
|
"mkfs.vfat -n efi /dev/vda1",
|
||||||
|
"mkfs.ext4 -L nixos /dev/crypt/nixos",
|
||||||
|
"mkswap -L swap /dev/crypt/swap",
|
||||||
|
"mount LABEL=nixos /mnt",
|
||||||
|
"mkdir -p /mnt/{etc/nixos,boot/efi}",
|
||||||
|
"mount LABEL=efi /mnt/boot/efi",
|
||||||
|
"swapon -L swap",
|
||||||
|
"mv luks.key /mnt/etc/nixos/"
|
||||||
|
)
|
||||||
|
'';
|
||||||
|
bootLoader = "grub";
|
||||||
|
grubUseEfi = true;
|
||||||
|
extraConfig = ''
|
||||||
|
boot.loader.grub.enableCryptodisk = true;
|
||||||
|
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||||
|
|
||||||
|
boot.initrd.secrets."/luks.key" = ./luks.key;
|
||||||
|
boot.initrd.luks.devices.crypt =
|
||||||
|
{ device = "/dev/vda2";
|
||||||
|
keyFile = "/luks.key";
|
||||||
|
};
|
||||||
|
'';
|
||||||
|
enableOCR = true;
|
||||||
|
preBootCommands = ''
|
||||||
|
machine.start()
|
||||||
|
machine.wait_for_text("Enter passphrase for")
|
||||||
|
machine.send_chars("supersecret\n")
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
swraid = makeInstallerTest "swraid" {
|
swraid = makeInstallerTest "swraid" {
|
||||||
createPartitions = ''
|
createPartitions = ''
|
||||||
machine.succeed(
|
machine.succeed(
|
||||||
|
|
46
nixos/tests/swap-file-btrfs.nix
Normal file
46
nixos/tests/swap-file-btrfs.nix
Normal file
|
@ -0,0 +1,46 @@
|
||||||
|
import ./make-test-python.nix ({ lib, ... }:
|
||||||
|
{
|
||||||
|
name = "swap-file-btrfs";
|
||||||
|
|
||||||
|
meta.maintainers = with lib.maintainers; [ oxalica ];
|
||||||
|
|
||||||
|
nodes.machine =
|
||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
virtualisation.useDefaultFilesystems = false;
|
||||||
|
|
||||||
|
virtualisation.bootDevice = "/dev/vda";
|
||||||
|
|
||||||
|
boot.initrd.postDeviceCommands = ''
|
||||||
|
${pkgs.btrfs-progs}/bin/mkfs.btrfs --label root /dev/vda
|
||||||
|
'';
|
||||||
|
|
||||||
|
virtualisation.fileSystems = {
|
||||||
|
"/" = {
|
||||||
|
device = "/dev/disk/by-label/root";
|
||||||
|
fsType = "btrfs";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [
|
||||||
|
{
|
||||||
|
device = "/var/swapfile";
|
||||||
|
size = 1; # 1MiB.
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
testScript = ''
|
||||||
|
machine.wait_for_unit('var-swapfile.swap')
|
||||||
|
machine.succeed("stat --file-system --format=%T /var/swapfile | grep btrfs")
|
||||||
|
# First run. Auto creation.
|
||||||
|
machine.succeed("swapon --show | grep /var/swapfile")
|
||||||
|
|
||||||
|
machine.shutdown()
|
||||||
|
machine.start()
|
||||||
|
|
||||||
|
# Second run. Use it as-is.
|
||||||
|
machine.wait_for_unit('var-swapfile.swap')
|
||||||
|
machine.succeed("swapon --show | grep /var/swapfile")
|
||||||
|
'';
|
||||||
|
})
|
35
nixos/tests/systemd-user-tmpfiles-rules.nix
Normal file
35
nixos/tests/systemd-user-tmpfiles-rules.nix
Normal file
|
@ -0,0 +1,35 @@
|
||||||
|
import ./make-test-python.nix ({ lib, ... }: {
|
||||||
|
name = "systemd-user-tmpfiles-rules";
|
||||||
|
|
||||||
|
meta = with lib.maintainers; {
|
||||||
|
maintainers = [ schnusch ];
|
||||||
|
};
|
||||||
|
|
||||||
|
nodes.machine = { ... }: {
|
||||||
|
users.users = {
|
||||||
|
alice.isNormalUser = true;
|
||||||
|
bob.isNormalUser = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.tmpfiles = {
|
||||||
|
rules = [
|
||||||
|
"d %h/user_tmpfiles_created"
|
||||||
|
];
|
||||||
|
users.alice.rules = [
|
||||||
|
"d %h/only_alice"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
testScript = { ... }: ''
|
||||||
|
machine.succeed("loginctl enable-linger alice bob")
|
||||||
|
|
||||||
|
machine.wait_until_succeeds("systemctl --user --machine=alice@ is-active systemd-tmpfiles-setup.service")
|
||||||
|
machine.succeed("[ -d ~alice/user_tmpfiles_created ]")
|
||||||
|
machine.succeed("[ -d ~alice/only_alice ]")
|
||||||
|
|
||||||
|
machine.wait_until_succeeds("systemctl --user --machine=bob@ is-active systemd-tmpfiles-setup.service")
|
||||||
|
machine.succeed("[ -d ~bob/user_tmpfiles_created ]")
|
||||||
|
machine.succeed("[ ! -e ~bob/only_alice ]")
|
||||||
|
'';
|
||||||
|
})
|
|
@ -18,7 +18,7 @@ import ./make-test-python.nix ({ pkgs, ... }: {
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
runHook preBuild
|
runHook preBuild
|
||||||
# just build the static lib we need for the go test binary
|
# just build the static lib we need for the go test binary
|
||||||
make $makeFlags ''${enableParallelBuilding:+-j$NIX_BUILD_CORES -l$NIX_BUILD_CORES} bpf-core ./dist/btfhub
|
make $makeFlags ''${enableParallelBuilding:+-j$NIX_BUILD_CORES} bpf-core ./dist/btfhub
|
||||||
|
|
||||||
# remove the /usr/bin prefix to work with the patch above
|
# remove the /usr/bin prefix to work with the patch above
|
||||||
substituteInPlace tests/integration/integration_test.go \
|
substituteInPlace tests/integration/integration_test.go \
|
||||||
|
|
|
@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
|
||||||
++ lib.optional podcastSupport python3.pkgs.feedparser
|
++ lib.optional podcastSupport python3.pkgs.feedparser
|
||||||
++ lib.optional wikipediaSupport webkitgtk;
|
++ lib.optional wikipediaSupport webkitgtk;
|
||||||
|
|
||||||
checkInputs = with python3.pkgs; [
|
nativeCheckInputs = with python3.pkgs; [
|
||||||
pytest
|
pytest
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
gnome.adwaita-icon-theme
|
gnome.adwaita-icon-theme
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = with python3Packages; [
|
nativeCheckInputs = with python3Packages; [
|
||||||
minimock
|
minimock
|
||||||
pytest
|
pytest
|
||||||
pytest-httpserver
|
pytest-httpserver
|
||||||
|
|
|
@ -50,6 +50,9 @@ stdenv.mkDerivation rec {
|
||||||
pipewire
|
pipewire
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# FIXME: workaround for Pipewire 0.3.64 deprecated API change, remove when fixed upstream
|
||||||
|
NIX_CFLAGS_COMPILE = [ "-DPW_ENABLE_DEPRECATED" ];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "A GTK patchbay for pipewire";
|
description = "A GTK patchbay for pipewire";
|
||||||
homepage = "https://gitlab.freedesktop.org/pipewire/helvum";
|
homepage = "https://gitlab.freedesktop.org/pipewire/helvum";
|
||||||
|
|
|
@ -13,7 +13,7 @@ in stdenv.mkDerivation {
|
||||||
sha256 = "05c6zskj50g29f51lx8fvgzsi3f31z01zj6ssjjrgr7jfs7ak70p";
|
sha256 = "05c6zskj50g29f51lx8fvgzsi3f31z01zj6ssjjrgr7jfs7ak70p";
|
||||||
};
|
};
|
||||||
|
|
||||||
checkInputs = (with dotnetPackages; [ NUnitConsole ]);
|
nativeCheckInputs = (with dotnetPackages; [ NUnitConsole ]);
|
||||||
nativeBuildInputs = [ mono makeWrapper ];
|
nativeBuildInputs = [ mono makeWrapper ];
|
||||||
|
|
||||||
buildPhase = ''
|
buildPhase = ''
|
||||||
|
|
|
@ -51,7 +51,7 @@ stdenv.mkDerivation rec {
|
||||||
Cocoa
|
Cocoa
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
cppunit
|
cppunit
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -27,6 +27,8 @@ lib.makeScope newScope (self: with self; {
|
||||||
|
|
||||||
mopidy-musicbox-webclient = callPackage ./musicbox-webclient.nix { };
|
mopidy-musicbox-webclient = callPackage ./musicbox-webclient.nix { };
|
||||||
|
|
||||||
|
mopidy-notify = callPackage ./notify.nix { };
|
||||||
|
|
||||||
mopidy-podcast = callPackage ./podcast.nix { };
|
mopidy-podcast = callPackage ./podcast.nix { };
|
||||||
|
|
||||||
mopidy-scrobbler = callPackage ./scrobbler.nix { };
|
mopidy-scrobbler = callPackage ./scrobbler.nix { };
|
||||||
|
@ -35,6 +37,8 @@ lib.makeScope newScope (self: with self; {
|
||||||
|
|
||||||
mopidy-soundcloud = callPackage ./soundcloud.nix { };
|
mopidy-soundcloud = callPackage ./soundcloud.nix { };
|
||||||
|
|
||||||
|
mopidy-tidal = callPackage ./tidal.nix { };
|
||||||
|
|
||||||
mopidy-tunein = callPackage ./tunein.nix { };
|
mopidy-tunein = callPackage ./tunein.nix { };
|
||||||
|
|
||||||
mopidy-youtube = callPackage ./youtube.nix { };
|
mopidy-youtube = callPackage ./youtube.nix { };
|
||||||
|
|
|
@ -28,7 +28,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
python3Packages.uritools
|
python3Packages.uritools
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
python3Packages.pytestCheckHook
|
python3Packages.pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
29
pkgs/applications/audio/mopidy/notify.nix
Normal file
29
pkgs/applications/audio/mopidy/notify.nix
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
{ lib, pythonPackages, mopidy }:
|
||||||
|
|
||||||
|
pythonPackages.buildPythonApplication rec {
|
||||||
|
pname = "Mopidy-Notify";
|
||||||
|
version = "0.2.0";
|
||||||
|
|
||||||
|
src = pythonPackages.fetchPypi {
|
||||||
|
inherit pname version;
|
||||||
|
sha256 = "sha256-lzZupjlS0kbNvsn18serOoMfu0sRb0nRwpowvOPvt/g=";
|
||||||
|
};
|
||||||
|
|
||||||
|
propagatedBuildInputs = [
|
||||||
|
mopidy
|
||||||
|
pythonPackages.pydbus
|
||||||
|
];
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
pythonPackages.pytestCheckHook
|
||||||
|
];
|
||||||
|
|
||||||
|
pythonImportsCheck = [ "mopidy_notify" ];
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
homepage = "https://github.com/phijor/mopidy-notify";
|
||||||
|
description = "Mopidy extension for showing desktop notifications on track change";
|
||||||
|
license = licenses.asl20;
|
||||||
|
maintainers = with maintainers; [ lilyinstarlight ];
|
||||||
|
};
|
||||||
|
}
|
|
@ -16,7 +16,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
python3Packages.uritools
|
python3Packages.uritools
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = with python3Packages; [
|
nativeCheckInputs = with python3Packages; [
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,7 @@ pythonPackages.buildPythonApplication rec {
|
||||||
|
|
||||||
propagatedBuildInputs = [ mopidy pythonPackages.py-sonic ];
|
propagatedBuildInputs = [ mopidy pythonPackages.py-sonic ];
|
||||||
|
|
||||||
checkInputs = with pythonPackages; [ pytestCheckHook ];
|
nativeCheckInputs = with pythonPackages; [ pytestCheckHook ];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://www.mopidy.com/";
|
homepage = "https://www.mopidy.com/";
|
||||||
|
|
35
pkgs/applications/audio/mopidy/tidal.nix
Normal file
35
pkgs/applications/audio/mopidy/tidal.nix
Normal file
|
@ -0,0 +1,35 @@
|
||||||
|
{ lib
|
||||||
|
, python3Packages
|
||||||
|
, mopidy
|
||||||
|
}:
|
||||||
|
|
||||||
|
python3Packages.buildPythonApplication rec {
|
||||||
|
pname = "Mopidy-Tidal";
|
||||||
|
version = "0.3.2";
|
||||||
|
|
||||||
|
src = python3Packages.fetchPypi {
|
||||||
|
inherit pname version;
|
||||||
|
hash = "sha256-ekqhzKyU2WqTOeRR1ZSZA9yW3UXsLBsC2Bk6FZrQgmc=";
|
||||||
|
};
|
||||||
|
|
||||||
|
propagatedBuildInputs = [
|
||||||
|
mopidy
|
||||||
|
python3Packages.tidalapi
|
||||||
|
];
|
||||||
|
|
||||||
|
nativeCheckInputs = with python3Packages; [
|
||||||
|
pytestCheckHook
|
||||||
|
pytest-mock
|
||||||
|
];
|
||||||
|
|
||||||
|
pytestFlagsArray = [ "tests/" ];
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Mopidy extension for playing music from Tidal";
|
||||||
|
homepage = "https://github.com/tehkillerbee/mopidy-tidal";
|
||||||
|
license = licenses.mit;
|
||||||
|
maintainers = [ maintainers.rodrgz ];
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||||
mopidy
|
mopidy
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = with python3.pkgs; [
|
nativeCheckInputs = with python3.pkgs; [
|
||||||
vcrpy
|
vcrpy
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
|
@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
|
|
||||||
checkInputs = [ ffmpeg glibcLocales perl ] ++ (with perlPackages; [ ListMoreUtils ]);
|
nativeCheckInputs = [ ffmpeg glibcLocales perl ] ++ (with perlPackages; [ ListMoreUtils ]);
|
||||||
|
|
||||||
checkPhase = ''
|
checkPhase = ''
|
||||||
export LANG="en_US.UTF-8"
|
export LANG="en_US.UTF-8"
|
||||||
|
|
|
@ -119,7 +119,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||||
|
|
||||||
LC_ALL = "en_US.UTF-8";
|
LC_ALL = "en_US.UTF-8";
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
dbus
|
dbus
|
||||||
gdk-pixbuf
|
gdk-pixbuf
|
||||||
glibcLocales
|
glibcLocales
|
||||||
|
|
|
@ -26,7 +26,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
propagatedBuildInputs = with python3Packages; [ crcmod ffmpeg-python mutagen tqdm ];
|
propagatedBuildInputs = with python3Packages; [ crcmod ffmpeg-python mutagen tqdm ];
|
||||||
checkInputs = with python3Packages; [ requests sox ];
|
nativeCheckInputs = with python3Packages; [ requests sox ];
|
||||||
|
|
||||||
# Testing downloads media files for testing, which requires the
|
# Testing downloads media files for testing, which requires the
|
||||||
# sandbox to be disabled.
|
# sandbox to be disabled.
|
||||||
|
|
|
@ -80,7 +80,7 @@ stdenv.mkDerivation rec {
|
||||||
"-DBUILD_TESTS=${if doCheck then "ON" else "OFF"}"
|
"-DBUILD_TESTS=${if doCheck then "ON" else "OFF"}"
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [ gtest ];
|
nativeCheckInputs = [ gtest ];
|
||||||
doCheck = !stdenv.isAarch64; # single failure that I can't explain
|
doCheck = !stdenv.isAarch64; # single failure that I can't explain
|
||||||
|
|
||||||
preFixup = ''
|
preFixup = ''
|
||||||
|
|
|
@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
|
||||||
libnotify
|
libnotify
|
||||||
] ++ gst_plugins;
|
] ++ gst_plugins;
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
check
|
check
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -92,7 +92,7 @@ stdenv.mkDerivation rec {
|
||||||
fmt
|
fmt
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
parallel
|
parallel
|
||||||
ruby
|
ruby
|
||||||
supercollider-with-sc3-plugins
|
supercollider-with-sc3-plugins
|
||||||
|
|
|
@ -37,7 +37,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
python3Packages.pygobject3
|
python3Packages.pygobject3
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
xvfb-run
|
xvfb-run
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -42,13 +42,13 @@ let
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "strawberry";
|
pname = "strawberry";
|
||||||
version = "1.0.13";
|
version = "1.0.14";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "jonaski";
|
owner = "jonaski";
|
||||||
repo = pname;
|
repo = pname;
|
||||||
rev = version;
|
rev = version;
|
||||||
hash = "sha256-szvCI1olC7GccJUGwR2Cx+FNGvfxeESsiSwWPTXWbc0=";
|
hash = "sha256-ThfycS5yNpp6+mE33qPqEWlhSB3OIF7d/t2XvI+rF2E=";
|
||||||
};
|
};
|
||||||
|
|
||||||
# the big strawberry shown in the context menu is *very* much in your face, so use the grey version instead
|
# the big strawberry shown in the context menu is *very* much in your face, so use the grey version instead
|
||||||
|
|
|
@ -73,7 +73,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
# https://github.com/NixOS/nixpkgs/issues/56943
|
# https://github.com/NixOS/nixpkgs/issues/56943
|
||||||
strictDeps = false;
|
strictDeps = false;
|
||||||
|
|
||||||
checkInputs = with python3Packages; [
|
nativeCheckInputs = with python3Packages; [
|
||||||
pytest
|
pytest
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -7,14 +7,14 @@
|
||||||
|
|
||||||
rustPlatform.buildRustPackage rec {
|
rustPlatform.buildRustPackage rec {
|
||||||
pname = "termusic";
|
pname = "termusic";
|
||||||
version = "0.7.7";
|
version = "0.7.8";
|
||||||
|
|
||||||
src = fetchCrate {
|
src = fetchCrate {
|
||||||
inherit pname version;
|
inherit pname version;
|
||||||
sha256 = "sha256-ynSNgiy8TUxRBDAi4rSPd5ztSLMaaFg1yEMTD1TI3V4=";
|
sha256 = "sha256-1RlG1/2+NuMO9zqFHQaEkEX1YrYYMjnaNprjdl1ZnHQ=";
|
||||||
};
|
};
|
||||||
|
|
||||||
cargoHash = "sha256-jD+oJw9xGY9ItYvoIUMwn8HrM72+02wOTeXEJjkZAfk=";
|
cargoHash = "sha256-SYk2SiFbp40/6Z0aBoX4MPnPLHjEfsJKCW4cErm0D78=";
|
||||||
|
|
||||||
nativeBuildInputs = [ pkg-config ];
|
nativeBuildInputs = [ pkg-config ];
|
||||||
buildInputs = [ alsa-lib ];
|
buildInputs = [ alsa-lib ];
|
||||||
|
|
|
@ -56,7 +56,7 @@ in python3.pkgs.buildPythonApplication rec {
|
||||||
|
|
||||||
buildInputs = [ libsndfile ];
|
buildInputs = [ libsndfile ];
|
||||||
|
|
||||||
checkInputs = with python3.pkgs; [
|
nativeCheckInputs = with python3.pkgs; [
|
||||||
twisted
|
twisted
|
||||||
] ++ bins;
|
] ++ bins;
|
||||||
|
|
||||||
|
|
|
@ -95,7 +95,7 @@ in stdenv.mkDerivation rec {
|
||||||
++ lib.optional (guiModule == "fltk") "-DFLTK_SKIP_OPENGL=ON";
|
++ lib.optional (guiModule == "fltk") "-DFLTK_SKIP_OPENGL=ON";
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
checkInputs = [ cxxtest ruby ];
|
nativeCheckInputs = [ cxxtest ruby ];
|
||||||
|
|
||||||
# TODO: Update cmake hook to make it simpler to selectively disable cmake tests: #113829
|
# TODO: Update cmake hook to make it simpler to selectively disable cmake tests: #113829
|
||||||
checkPhase = let
|
checkPhase = let
|
||||||
|
|
|
@ -40,7 +40,7 @@ python3.pkgs.buildPythonApplication rec {
|
||||||
pyunifiprotect
|
pyunifiprotect
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = with python3.pkgs; [
|
nativeCheckInputs = with python3.pkgs; [
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -52,7 +52,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
)
|
)
|
||||||
'';
|
'';
|
||||||
|
|
||||||
checkInputs = with python3Packages; [
|
nativeCheckInputs = with python3Packages; [
|
||||||
pytest-qt
|
pytest-qt
|
||||||
pytest-mock
|
pytest-mock
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
|
|
|
@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
|
||||||
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
|
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [ python3 ];
|
nativeCheckInputs = [ python3 ];
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
|
|
||||||
|
|
|
@ -73,7 +73,7 @@ stdenv.mkDerivation rec {
|
||||||
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
|
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [ python3 ];
|
nativeCheckInputs = [ python3 ];
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
|
|
||||||
|
|
|
@ -40,7 +40,7 @@ python3Packages.buildPythonApplication rec {
|
||||||
pytimeparse
|
pytimeparse
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = with python3Packages; [
|
nativeCheckInputs = with python3Packages; [
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
pytest-asyncio
|
pytest-asyncio
|
||||||
];
|
];
|
||||||
|
|
|
@ -64,7 +64,7 @@ let chia = python3Packages.buildPythonApplication rec {
|
||||||
zstd
|
zstd
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = with python3Packages; [
|
nativeCheckInputs = with python3Packages; [
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -62,7 +62,7 @@ stdenv.mkDerivation rec {
|
||||||
# https://github.com/NixOS/nixpkgs/issues/179474
|
# https://github.com/NixOS/nixpkgs/issues/179474
|
||||||
hardeningDisable = lib.optionals (stdenv.isAarch64 && stdenv.isDarwin) [ "fortify" "stackprotector" ];
|
hardeningDisable = lib.optionals (stdenv.isAarch64 && stdenv.isDarwin) [ "fortify" "stackprotector" ];
|
||||||
|
|
||||||
checkInputs = [ python3 ];
|
nativeCheckInputs = [ python3 ];
|
||||||
|
|
||||||
doCheck = true;
|
doCheck = true;
|
||||||
|
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
let
|
let
|
||||||
pname = "erigon";
|
pname = "erigon";
|
||||||
version = "2.34.0";
|
version = "2.35.2";
|
||||||
in
|
in
|
||||||
buildGoModule {
|
buildGoModule {
|
||||||
inherit pname version;
|
inherit pname version;
|
||||||
|
@ -11,11 +11,11 @@ buildGoModule {
|
||||||
owner = "ledgerwatch";
|
owner = "ledgerwatch";
|
||||||
repo = pname;
|
repo = pname;
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
sha256 = "sha256-oiFPnDzvLdVkGeflqUcB00peZyVLMzsXi7QzOjPlpHo=";
|
sha256 = "sha256-hGJ9SeUYACOuypTJmPnrv4f8ujjsUt3dZbwso+94g3M=";
|
||||||
fetchSubmodules = true;
|
fetchSubmodules = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
vendorSha256 = "sha256-x/ffvbBKzJrssOo+cuWIiwHWu9UfeBHSbgwmLE0340A=";
|
vendorSha256 = "sha256-lKzJLRCcyhQIV7y1XxqbvTINLlUwWFnflZgGQHYzBjY=";
|
||||||
proxyVendor = true;
|
proxyVendor = true;
|
||||||
|
|
||||||
# Build errors in mdbx when format hardening is enabled:
|
# Build errors in mdbx when format hardening is enabled:
|
||||||
|
|
|
@ -7,7 +7,7 @@ stdenv.mkDerivation rec {
|
||||||
version = "22.8.12";
|
version = "22.8.12";
|
||||||
|
|
||||||
src = fetchzip {
|
src = fetchzip {
|
||||||
url = "https://downloads.exodus.io/releases/${pname}-linux-x64-${version}.zip";
|
url = "https://downloads.exodus.com/releases/${pname}-linux-x64-${version}.zip";
|
||||||
sha256 = "sha256-jNzHh4zYhFzpFZAC9rHmwjTdFkbpROSEN3qpL7geiOU=";
|
sha256 = "sha256-jNzHh4zYhFzpFZAC9rHmwjTdFkbpROSEN3qpL7geiOU=";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -67,7 +67,7 @@ stdenv.mkDerivation rec {
|
||||||
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
|
"--with-qt-bindir=${qtbase.dev}/bin:${qttools.dev}/bin"
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [ python3 ];
|
nativeCheckInputs = [ python3 ];
|
||||||
|
|
||||||
checkFlags = [ "LC_ALL=en_US.UTF-8" ]
|
checkFlags = [ "LC_ALL=en_US.UTF-8" ]
|
||||||
# QT_PLUGIN_PATH needs to be set when executing QT, which is needed when testing Groestlcoin's GUI.
|
# QT_PLUGIN_PATH needs to be set when executing QT, which is needed when testing Groestlcoin's GUI.
|
||||||
|
|
|
@ -15,6 +15,7 @@
|
||||||
, testers
|
, testers
|
||||||
, unzip
|
, unzip
|
||||||
, nix-update-script
|
, nix-update-script
|
||||||
|
, SystemConfiguration
|
||||||
}:
|
}:
|
||||||
|
|
||||||
rustPlatform.buildRustPackage rec {
|
rustPlatform.buildRustPackage rec {
|
||||||
|
@ -41,7 +42,7 @@ rustPlatform.buildRustPackage rec {
|
||||||
buildInputs = lib.optionals stdenv.isDarwin [
|
buildInputs = lib.optionals stdenv.isDarwin [
|
||||||
Security
|
Security
|
||||||
] ++ lib.optionals (stdenv.isDarwin && stdenv.isx86_64) [
|
] ++ lib.optionals (stdenv.isDarwin && stdenv.isx86_64) [
|
||||||
CoreFoundation
|
CoreFoundation SystemConfiguration
|
||||||
];
|
];
|
||||||
|
|
||||||
depositContractSpec = fetchurl {
|
depositContractSpec = fetchurl {
|
||||||
|
@ -86,7 +87,7 @@ rustPlatform.buildRustPackage rec {
|
||||||
"--skip subnet_service::tests::sync_committee_service::subscribe_and_unsubscribe"
|
"--skip subnet_service::tests::sync_committee_service::subscribe_and_unsubscribe"
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
nodePackages.ganache
|
nodePackages.ganache
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -38,7 +38,7 @@ rustPlatform.buildRustPackage rec {
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
|
|
||||||
# all the following are needed for the checkphase
|
# all the following are needed for the checkphase
|
||||||
# checkInputs = lib.optionals stdenv.isDarwin [ pkg-config rustfmt ];
|
# nativeCheckInputs = lib.optionals stdenv.isDarwin [ pkg-config rustfmt ];
|
||||||
# Needed to get openssl-sys to use pkg-config.
|
# Needed to get openssl-sys to use pkg-config.
|
||||||
# OPENSSL_NO_VENDOR = 1;
|
# OPENSSL_NO_VENDOR = 1;
|
||||||
# OPENSSL_LIB_DIR = "${lib.getLib openssl}/lib";
|
# OPENSSL_LIB_DIR = "${lib.getLib openssl}/lib";
|
||||||
|
|
33
pkgs/applications/blockchains/torq/default.nix
Normal file
33
pkgs/applications/blockchains/torq/default.nix
Normal file
|
@ -0,0 +1,33 @@
|
||||||
|
{ lib
|
||||||
|
, buildGoModule
|
||||||
|
, fetchFromGitHub
|
||||||
|
}:
|
||||||
|
|
||||||
|
buildGoModule rec {
|
||||||
|
pname = "torq";
|
||||||
|
version = "0.16.15";
|
||||||
|
|
||||||
|
src = fetchFromGitHub {
|
||||||
|
owner = "lncapital";
|
||||||
|
repo = pname;
|
||||||
|
rev = "v${version}";
|
||||||
|
hash = "sha256-ibrPq/EC61ssn4072gTNvJg9QO41+aTsU1Hhc6X6NPk=";
|
||||||
|
};
|
||||||
|
|
||||||
|
vendorHash = "sha256-HETN2IMnpxnTyg6bQDpoD0saJu+gKocdEf0VzEi12Gs=";
|
||||||
|
|
||||||
|
subPackages = [ "cmd/torq" ];
|
||||||
|
|
||||||
|
ldflags = [
|
||||||
|
"-s"
|
||||||
|
"-w"
|
||||||
|
"-X github.com/lncapital/torq/build.version=v${version}"
|
||||||
|
];
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Capital management tool for lightning network nodes";
|
||||||
|
license = licenses.mit;
|
||||||
|
homepage = "https://github.com/lncapital/torq";
|
||||||
|
maintainers = with maintainers; [ mmilata prusnak ];
|
||||||
|
};
|
||||||
|
}
|
|
@ -1,34 +1,34 @@
|
||||||
{ lib
|
{
|
||||||
, stdenv
|
lib,
|
||||||
, fetchFromGitHub
|
stdenv,
|
||||||
, buildDotnetModule
|
fetchFromGitHub,
|
||||||
, dotnetCorePackages
|
buildDotnetModule,
|
||||||
, autoPatchelfHook
|
dotnetCorePackages,
|
||||||
, zlib
|
autoPatchelfHook,
|
||||||
, openssl
|
zlib,
|
||||||
|
openssl,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildDotnetModule rec {
|
buildDotnetModule rec {
|
||||||
pname = "wasabibackend";
|
pname = "wasabibackend";
|
||||||
version = "1.1.13.1";
|
version = "2.0.2.1";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "zkSNACKs";
|
owner = "zkSNACKs";
|
||||||
repo = "WalletWasabi";
|
repo = "WalletWasabi";
|
||||||
rev = "v${version}";
|
rev = "refs/tags/v${version}";
|
||||||
sha256 = "sha256-Hwav7moG6XKAcR7L0Q7CtifP3zCNRfHIihlaFw+dzbk=";
|
hash = "sha512-JuCl3SyejzwUd2n8Fy7EdxUuO4bIcGb8yMWZQOhZzsY4fvg9prFOnVZEquxahD0a41MLKHRNA1R2N3NMapcc0A==";
|
||||||
};
|
};
|
||||||
|
|
||||||
projectFile = "WalletWasabi.Backend/WalletWasabi.Backend.csproj";
|
projectFile = "WalletWasabi.Backend/WalletWasabi.Backend.csproj";
|
||||||
nugetDeps = ./deps.nix;
|
nugetDeps = ./deps.nix;
|
||||||
|
|
||||||
dotnet-sdk = dotnetCorePackages.sdk_3_1;
|
dotnet-sdk = dotnetCorePackages.sdk_7_0;
|
||||||
dotnet-runtime = dotnetCorePackages.aspnetcore_3_1;
|
dotnet-runtime = dotnetCorePackages.aspnetcore_7_0;
|
||||||
|
|
||||||
nativeBuildInputs = [ autoPatchelfHook ];
|
nativeBuildInputs = [autoPatchelfHook];
|
||||||
buildInputs = [ stdenv.cc.cc.lib zlib ];
|
buildInputs = [stdenv.cc.cc.lib zlib];
|
||||||
|
|
||||||
runtimeDeps = [ openssl zlib ];
|
runtimeDeps = [openssl zlib];
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
makeWrapperArgs+=(
|
makeWrapperArgs+=(
|
||||||
|
@ -43,9 +43,9 @@ buildDotnetModule rec {
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Backend for the Wasabi Wallet";
|
description = "Backend for the Wasabi Wallet";
|
||||||
homepage = "https://wasabiwallet.io/";
|
homepage = "https://wasabiwallet.io/";
|
||||||
sourceProvenance = with sourceTypes; [ binaryNativeCode ];
|
sourceProvenance = with sourceTypes; [binaryNativeCode];
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
maintainers = with maintainers; [ mmahut ];
|
maintainers = with maintainers; [mmahut];
|
||||||
platforms = [ "x86_64-linux" ];
|
platforms = ["x86_64-linux"];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
28
pkgs/applications/blockchains/wasabibackend/deps.nix
generated
28
pkgs/applications/blockchains/wasabibackend/deps.nix
generated
|
@ -2,8 +2,8 @@
|
||||||
# Please dont edit it manually, your changes might get overwritten!
|
# Please dont edit it manually, your changes might get overwritten!
|
||||||
|
|
||||||
{ fetchNuGet }: [
|
{ fetchNuGet }: [
|
||||||
(fetchNuGet { pname = "Microsoft.AspNetCore.JsonPatch"; version = "3.1.1"; sha256 = "0c0aaz9rlh9chc53dnv5jryp0x0415hipaizrmih3kzwd3fmqpml"; })
|
(fetchNuGet { pname = "Microsoft.AspNetCore.JsonPatch"; version = "7.0.0"; sha256 = "1f13vsfs1rp9bmdp3khk4mk2fif932d72yxm2wszpsr239x4s2bf"; })
|
||||||
(fetchNuGet { pname = "Microsoft.AspNetCore.Mvc.NewtonsoftJson"; version = "3.1.1"; sha256 = "1c2lrlp64kkacnjgdyygr6fqdawk10l8j4qgppii6rq61yjwhcig"; })
|
(fetchNuGet { pname = "Microsoft.AspNetCore.Mvc.NewtonsoftJson"; version = "7.0.0"; sha256 = "1w49rg0n5wb1m5wnays2mmym7qy7bsi2b1zxz97af2rkbw3s3hbd"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Build"; version = "15.3.409"; sha256 = "0vzq6csp2yys9s96c7i37bjml439rdi47g8f5rzqdr7xf5a1jk81"; })
|
(fetchNuGet { pname = "Microsoft.Build"; version = "15.3.409"; sha256 = "0vzq6csp2yys9s96c7i37bjml439rdi47g8f5rzqdr7xf5a1jk81"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Build.Framework"; version = "15.3.409"; sha256 = "1dhanwb9ihbfay85xj7cwn0byzmmdz94hqfi3q6r1ncwdjd8y1s2"; })
|
(fetchNuGet { pname = "Microsoft.Build.Framework"; version = "15.3.409"; sha256 = "1dhanwb9ihbfay85xj7cwn0byzmmdz94hqfi3q6r1ncwdjd8y1s2"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Build.Runtime"; version = "15.3.409"; sha256 = "135ycnqz5jfg61y5zaapgc7xdpjx2aq4icmxb9ph7h5inl445q7q"; })
|
(fetchNuGet { pname = "Microsoft.Build.Runtime"; version = "15.3.409"; sha256 = "135ycnqz5jfg61y5zaapgc7xdpjx2aq4icmxb9ph7h5inl445q7q"; })
|
||||||
|
@ -11,7 +11,7 @@
|
||||||
(fetchNuGet { pname = "Microsoft.Build.Utilities.Core"; version = "15.3.409"; sha256 = "1p8a0l9sxmjj86qha748qjw2s2n07q8mn41mj5r6apjnwl27ywnf"; })
|
(fetchNuGet { pname = "Microsoft.Build.Utilities.Core"; version = "15.3.409"; sha256 = "1p8a0l9sxmjj86qha748qjw2s2n07q8mn41mj5r6apjnwl27ywnf"; })
|
||||||
(fetchNuGet { pname = "Microsoft.CSharp"; version = "4.3.0"; sha256 = "0gw297dgkh0al1zxvgvncqs0j15lsna9l1wpqas4rflmys440xvb"; })
|
(fetchNuGet { pname = "Microsoft.CSharp"; version = "4.3.0"; sha256 = "0gw297dgkh0al1zxvgvncqs0j15lsna9l1wpqas4rflmys440xvb"; })
|
||||||
(fetchNuGet { pname = "Microsoft.CSharp"; version = "4.7.0"; sha256 = "0gd67zlw554j098kabg887b5a6pq9kzavpa3jjy5w53ccjzjfy8j"; })
|
(fetchNuGet { pname = "Microsoft.CSharp"; version = "4.7.0"; sha256 = "0gd67zlw554j098kabg887b5a6pq9kzavpa3jjy5w53ccjzjfy8j"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Extensions.ApiDescription.Server"; version = "3.0.0"; sha256 = "13a47xcqyi5gz85swxd4mgp7ndgl4kknrvv3xwmbn71hsh953hsh"; })
|
(fetchNuGet { pname = "Microsoft.Extensions.ApiDescription.Server"; version = "6.0.5"; sha256 = "1pi2bm3cm0a7jzqzmfc2r7bpcdkmk3hhjfvb2c81j7wl7xdw3624"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Extensions.FileProviders.Abstractions"; version = "2.0.0"; sha256 = "0d6y5isjy6jpf4w3f3w89cwh9p40glzhwvm7cwhx05wkqd8bk9w4"; })
|
(fetchNuGet { pname = "Microsoft.Extensions.FileProviders.Abstractions"; version = "2.0.0"; sha256 = "0d6y5isjy6jpf4w3f3w89cwh9p40glzhwvm7cwhx05wkqd8bk9w4"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Extensions.FileProviders.Physical"; version = "2.0.0"; sha256 = "0l0l92g7sq4122n139av1pn1jl6wlw92hjmdnr47xdss0ndmwrs3"; })
|
(fetchNuGet { pname = "Microsoft.Extensions.FileProviders.Physical"; version = "2.0.0"; sha256 = "0l0l92g7sq4122n139av1pn1jl6wlw92hjmdnr47xdss0ndmwrs3"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Extensions.FileSystemGlobbing"; version = "2.0.0"; sha256 = "02lzy6r14ghwfwm384xajq08vv3pl3ww0mi5isrr10vivhijhgg4"; })
|
(fetchNuGet { pname = "Microsoft.Extensions.FileSystemGlobbing"; version = "2.0.0"; sha256 = "02lzy6r14ghwfwm384xajq08vv3pl3ww0mi5isrr10vivhijhgg4"; })
|
||||||
|
@ -24,22 +24,20 @@
|
||||||
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "1.0.1"; sha256 = "01al6cfxp68dscl15z7rxfw9zvhm64dncsw09a1vmdkacsa2v6lr"; })
|
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "1.0.1"; sha256 = "01al6cfxp68dscl15z7rxfw9zvhm64dncsw09a1vmdkacsa2v6lr"; })
|
||||||
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "1.1.0"; sha256 = "08vh1r12g6ykjygq5d3vq09zylgb84l63k49jc4v8faw9g93iqqm"; })
|
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "1.1.0"; sha256 = "08vh1r12g6ykjygq5d3vq09zylgb84l63k49jc4v8faw9g93iqqm"; })
|
||||||
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "2.0.1"; sha256 = "1j2hmnivgb4plni2dd205kafzg6mkg7r4knrd3s7mg75wn2l25np"; })
|
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "2.0.1"; sha256 = "1j2hmnivgb4plni2dd205kafzg6mkg7r4knrd3s7mg75wn2l25np"; })
|
||||||
(fetchNuGet { pname = "Microsoft.NETCore.Platforms"; version = "3.1.0"; sha256 = "1gc1x8f95wk8yhgznkwsg80adk1lc65v9n5rx4yaa4bc5dva0z3j"; })
|
|
||||||
(fetchNuGet { pname = "Microsoft.NETCore.Targets"; version = "1.0.1"; sha256 = "0ppdkwy6s9p7x9jix3v4402wb171cdiibq7js7i13nxpdky7074p"; })
|
(fetchNuGet { pname = "Microsoft.NETCore.Targets"; version = "1.0.1"; sha256 = "0ppdkwy6s9p7x9jix3v4402wb171cdiibq7js7i13nxpdky7074p"; })
|
||||||
(fetchNuGet { pname = "Microsoft.NETCore.Targets"; version = "1.1.0"; sha256 = "193xwf33fbm0ni3idxzbr5fdq3i2dlfgihsac9jj7whj0gd902nh"; })
|
(fetchNuGet { pname = "Microsoft.NETCore.Targets"; version = "1.1.0"; sha256 = "193xwf33fbm0ni3idxzbr5fdq3i2dlfgihsac9jj7whj0gd902nh"; })
|
||||||
(fetchNuGet { pname = "Microsoft.OpenApi"; version = "1.1.4"; sha256 = "1sn79829nhx6chi2qxsza1801di7zdl5fd983m0jakawzbjhjcb3"; })
|
(fetchNuGet { pname = "Microsoft.OpenApi"; version = "1.2.3"; sha256 = "07b19k89whj69j87afkz86gp9b3iybw8jqwvlgcn43m7fb2y99rr"; })
|
||||||
(fetchNuGet { pname = "Microsoft.VisualStudio.Web.CodeGeneration.Contracts"; version = "2.0.2"; sha256 = "1fs6sbjn0chx6rv38d61zgk8mhyyxz44xp4wsfya0lvkckyszyn1"; })
|
(fetchNuGet { pname = "Microsoft.VisualStudio.Web.CodeGeneration.Contracts"; version = "2.0.2"; sha256 = "1fs6sbjn0chx6rv38d61zgk8mhyyxz44xp4wsfya0lvkckyszyn1"; })
|
||||||
(fetchNuGet { pname = "Microsoft.VisualStudio.Web.CodeGeneration.Tools"; version = "2.0.2"; sha256 = "0fkjm06irs53d77z29i6dwj5pjhgj9ivhad8v39ghnrwasc0ivq6"; })
|
(fetchNuGet { pname = "Microsoft.VisualStudio.Web.CodeGeneration.Tools"; version = "2.0.2"; sha256 = "0fkjm06irs53d77z29i6dwj5pjhgj9ivhad8v39ghnrwasc0ivq6"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Win32.Primitives"; version = "4.0.1"; sha256 = "1n8ap0cmljbqskxpf8fjzn7kh1vvlndsa75k01qig26mbw97k2q7"; })
|
(fetchNuGet { pname = "Microsoft.Win32.Primitives"; version = "4.0.1"; sha256 = "1n8ap0cmljbqskxpf8fjzn7kh1vvlndsa75k01qig26mbw97k2q7"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Win32.Registry"; version = "4.0.0"; sha256 = "1spf4m9pikkc19544p29a47qnhcd885klncahz133hbnyqbkmz9k"; })
|
(fetchNuGet { pname = "Microsoft.Win32.Registry"; version = "4.0.0"; sha256 = "1spf4m9pikkc19544p29a47qnhcd885klncahz133hbnyqbkmz9k"; })
|
||||||
(fetchNuGet { pname = "Microsoft.Win32.Registry"; version = "4.7.0"; sha256 = "0bx21jjbs7l5ydyw4p6cn07chryxpmchq2nl5pirzz4l3b0q4dgs"; })
|
(fetchNuGet { pname = "Microsoft.Win32.SystemEvents"; version = "7.0.0"; sha256 = "1bh77misznh19m1swqm3dsbji499b8xh9gk6w74sgbkarf6ni8lb"; })
|
||||||
(fetchNuGet { pname = "NBitcoin"; version = "5.0.81"; sha256 = "1fba94kc8yzykb1m5lvpx1hm63mpycpww9cz5zfp85phs1spdn8x"; })
|
(fetchNuGet { pname = "NBitcoin"; version = "7.0.14"; sha256 = "18nxx13fz3i7kmigijnynvrbx2i5cb3v4m89nvnxl38vcw7w5jys"; })
|
||||||
(fetchNuGet { pname = "NBitcoin.Secp256k1"; version = "1.0.10"; sha256 = "14hngbhxk2xjr5kcbsb26l788xnd1lmxn7fhmm2kvx49kdb1malp"; })
|
(fetchNuGet { pname = "NBitcoin.Secp256k1"; version = "3.0.1"; sha256 = "17wxn0dinmp5fbqdirflfkz75wykqvw9a7ydv2inx1sajxnsy1f3"; })
|
||||||
(fetchNuGet { pname = "NETStandard.Library"; version = "1.6.0"; sha256 = "0nmmv4yw7gw04ik8ialj3ak0j6pxa9spih67hnn1h2c38ba8h58k"; })
|
(fetchNuGet { pname = "NETStandard.Library"; version = "1.6.0"; sha256 = "0nmmv4yw7gw04ik8ialj3ak0j6pxa9spih67hnn1h2c38ba8h58k"; })
|
||||||
(fetchNuGet { pname = "NETStandard.Library"; version = "2.0.1"; sha256 = "0d44wjxphs1ck838v7dapm0ag0b91zpiy33cr5vflsrwrqgj51dk"; })
|
(fetchNuGet { pname = "NETStandard.Library"; version = "2.0.1"; sha256 = "0d44wjxphs1ck838v7dapm0ag0b91zpiy33cr5vflsrwrqgj51dk"; })
|
||||||
(fetchNuGet { pname = "Newtonsoft.Json"; version = "10.0.1"; sha256 = "15ncqic3p2rzs8q8ppi0irl2miq75kilw4lh8yfgjq96id0ds3hv"; })
|
(fetchNuGet { pname = "Newtonsoft.Json"; version = "10.0.1"; sha256 = "15ncqic3p2rzs8q8ppi0irl2miq75kilw4lh8yfgjq96id0ds3hv"; })
|
||||||
(fetchNuGet { pname = "Newtonsoft.Json"; version = "11.0.2"; sha256 = "1784xi44f4k8v1fr696hsccmwpy94bz7kixxqlri98zhcxn406b2"; })
|
(fetchNuGet { pname = "Newtonsoft.Json"; version = "13.0.1"; sha256 = "0fijg0w6iwap8gvzyjnndds0q4b8anwxxvik7y8vgq97dram4srb"; })
|
||||||
(fetchNuGet { pname = "Newtonsoft.Json"; version = "12.0.2"; sha256 = "0w2fbji1smd2y7x25qqibf1qrznmv4s6s0jvrbvr6alb7mfyqvh5"; })
|
|
||||||
(fetchNuGet { pname = "Newtonsoft.Json.Bson"; version = "1.0.2"; sha256 = "0c27bhy9x3c2n26inq32kmp6drpm71n6mqnmcr19wrlcaihglj35"; })
|
(fetchNuGet { pname = "Newtonsoft.Json.Bson"; version = "1.0.2"; sha256 = "0c27bhy9x3c2n26inq32kmp6drpm71n6mqnmcr19wrlcaihglj35"; })
|
||||||
(fetchNuGet { pname = "NuGet.Frameworks"; version = "4.0.0"; sha256 = "0nar684cm53cvzx28gzl6kmpg9mrfr1yv29323din7xqal4pscgq"; })
|
(fetchNuGet { pname = "NuGet.Frameworks"; version = "4.0.0"; sha256 = "0nar684cm53cvzx28gzl6kmpg9mrfr1yv29323din7xqal4pscgq"; })
|
||||||
(fetchNuGet { pname = "runtime.any.System.Collections"; version = "4.0.11"; sha256 = "1x44bm1cgv28zmrp095wf9mn8a6a0ivnzp9v14dcbhx06igxzgg0"; })
|
(fetchNuGet { pname = "runtime.any.System.Collections"; version = "4.0.11"; sha256 = "1x44bm1cgv28zmrp095wf9mn8a6a0ivnzp9v14dcbhx06igxzgg0"; })
|
||||||
|
@ -61,10 +59,10 @@
|
||||||
(fetchNuGet { pname = "runtime.unix.System.Diagnostics.Debug"; version = "4.0.11"; sha256 = "05ndbai4vpqrry0ghbfgqc8xblmplwjgndxmdn1zklqimczwjg2d"; })
|
(fetchNuGet { pname = "runtime.unix.System.Diagnostics.Debug"; version = "4.0.11"; sha256 = "05ndbai4vpqrry0ghbfgqc8xblmplwjgndxmdn1zklqimczwjg2d"; })
|
||||||
(fetchNuGet { pname = "runtime.unix.System.Private.Uri"; version = "4.0.1"; sha256 = "0ic5dgc45jkhcr1g9xmmzjm7ffiw4cymm0fprczlx4fnww4783nm"; })
|
(fetchNuGet { pname = "runtime.unix.System.Private.Uri"; version = "4.0.1"; sha256 = "0ic5dgc45jkhcr1g9xmmzjm7ffiw4cymm0fprczlx4fnww4783nm"; })
|
||||||
(fetchNuGet { pname = "runtime.unix.System.Runtime.Extensions"; version = "4.1.0"; sha256 = "0x1cwd7cvifzmn5x1wafvj75zdxlk3mxy860igh3x1wx0s8167y4"; })
|
(fetchNuGet { pname = "runtime.unix.System.Runtime.Extensions"; version = "4.1.0"; sha256 = "0x1cwd7cvifzmn5x1wafvj75zdxlk3mxy860igh3x1wx0s8167y4"; })
|
||||||
(fetchNuGet { pname = "Swashbuckle.AspNetCore"; version = "5.0.0"; sha256 = "0rn2awmzrsrppk97xbbwk4kq1mys9bygb5xhl6mphbk0hchrvh09"; })
|
(fetchNuGet { pname = "Swashbuckle.AspNetCore"; version = "6.4.0"; sha256 = "1jkgjnkjcb6dif0lzn7whjwwdd4fi6mzkmkdx8sfmv5cffzq4fvk"; })
|
||||||
(fetchNuGet { pname = "Swashbuckle.AspNetCore.Swagger"; version = "5.0.0"; sha256 = "1341nv8nmh6avs3y7w2szzir5qd0bndxwrkdmvvj3hcxj1126w2f"; })
|
(fetchNuGet { pname = "Swashbuckle.AspNetCore.Swagger"; version = "6.4.0"; sha256 = "1wccx8ig2xc6xcfh774m5z34w6jn0hjffiwc5sq9yl63zkv01vnn"; })
|
||||||
(fetchNuGet { pname = "Swashbuckle.AspNetCore.SwaggerGen"; version = "5.0.0"; sha256 = "00swg2avqnb38q2bsxljd34n8rpknp74h9vbn0fdnfds3a32cqr4"; })
|
(fetchNuGet { pname = "Swashbuckle.AspNetCore.SwaggerGen"; version = "6.4.0"; sha256 = "1k58j6lfqcgrl5f7dw0xnbq6w5bvr42a9fc44vwbzl52kzjdlnh2"; })
|
||||||
(fetchNuGet { pname = "Swashbuckle.AspNetCore.SwaggerUI"; version = "5.0.0"; sha256 = "0d7vjq489rz208j6k3rb7vq6mzxzff3mqg83yk2rqy25vklrsbjd"; })
|
(fetchNuGet { pname = "Swashbuckle.AspNetCore.SwaggerUI"; version = "6.4.0"; sha256 = "1rxgf0hbkkzywh8z7asky2rrh1gpnrr514v1aj5vnmh49sa31kiz"; })
|
||||||
(fetchNuGet { pname = "System.AppContext"; version = "4.1.0"; sha256 = "0fv3cma1jp4vgj7a8hqc9n7hr1f1kjp541s6z0q1r6nazb4iz9mz"; })
|
(fetchNuGet { pname = "System.AppContext"; version = "4.1.0"; sha256 = "0fv3cma1jp4vgj7a8hqc9n7hr1f1kjp541s6z0q1r6nazb4iz9mz"; })
|
||||||
(fetchNuGet { pname = "System.Buffers"; version = "4.0.0"; sha256 = "13s659bcmg9nwb6z78971z1lr6bmh2wghxi1ayqyzl4jijd351gr"; })
|
(fetchNuGet { pname = "System.Buffers"; version = "4.0.0"; sha256 = "13s659bcmg9nwb6z78971z1lr6bmh2wghxi1ayqyzl4jijd351gr"; })
|
||||||
(fetchNuGet { pname = "System.Collections"; version = "4.0.11"; sha256 = "1ga40f5lrwldiyw6vy67d0sg7jd7ww6kgwbksm19wrvq9hr0bsm6"; })
|
(fetchNuGet { pname = "System.Collections"; version = "4.0.11"; sha256 = "1ga40f5lrwldiyw6vy67d0sg7jd7ww6kgwbksm19wrvq9hr0bsm6"; })
|
||||||
|
@ -152,7 +150,6 @@
|
||||||
(fetchNuGet { pname = "System.Runtime.Serialization.Primitives"; version = "4.1.1"; sha256 = "042rfjixknlr6r10vx2pgf56yming8lkjikamg3g4v29ikk78h7k"; })
|
(fetchNuGet { pname = "System.Runtime.Serialization.Primitives"; version = "4.1.1"; sha256 = "042rfjixknlr6r10vx2pgf56yming8lkjikamg3g4v29ikk78h7k"; })
|
||||||
(fetchNuGet { pname = "System.Runtime.Serialization.Primitives"; version = "4.3.0"; sha256 = "01vv2p8h4hsz217xxs0rixvb7f2xzbh6wv1gzbfykcbfrza6dvnf"; })
|
(fetchNuGet { pname = "System.Runtime.Serialization.Primitives"; version = "4.3.0"; sha256 = "01vv2p8h4hsz217xxs0rixvb7f2xzbh6wv1gzbfykcbfrza6dvnf"; })
|
||||||
(fetchNuGet { pname = "System.Runtime.Serialization.Xml"; version = "4.1.1"; sha256 = "11747an5gbz821pwahaim3v82gghshnj9b5c4cw539xg5a3gq7rk"; })
|
(fetchNuGet { pname = "System.Runtime.Serialization.Xml"; version = "4.1.1"; sha256 = "11747an5gbz821pwahaim3v82gghshnj9b5c4cw539xg5a3gq7rk"; })
|
||||||
(fetchNuGet { pname = "System.Security.AccessControl"; version = "4.7.0"; sha256 = "0n0k0w44flkd8j0xw7g3g3vhw7dijfm51f75xkm1qxnbh4y45mpz"; })
|
|
||||||
(fetchNuGet { pname = "System.Security.Cryptography.Algorithms"; version = "4.2.0"; sha256 = "148s9g5dgm33ri7dnh19s4lgnlxbpwvrw2jnzllq2kijj4i4vs85"; })
|
(fetchNuGet { pname = "System.Security.Cryptography.Algorithms"; version = "4.2.0"; sha256 = "148s9g5dgm33ri7dnh19s4lgnlxbpwvrw2jnzllq2kijj4i4vs85"; })
|
||||||
(fetchNuGet { pname = "System.Security.Cryptography.Cng"; version = "4.2.0"; sha256 = "118jijz446kix20blxip0f0q8mhsh9bz118mwc2ch1p6g7facpzc"; })
|
(fetchNuGet { pname = "System.Security.Cryptography.Cng"; version = "4.2.0"; sha256 = "118jijz446kix20blxip0f0q8mhsh9bz118mwc2ch1p6g7facpzc"; })
|
||||||
(fetchNuGet { pname = "System.Security.Cryptography.Csp"; version = "4.0.0"; sha256 = "1cwv8lqj8r15q81d2pz2jwzzbaji0l28xfrpw29kdpsaypm92z2q"; })
|
(fetchNuGet { pname = "System.Security.Cryptography.Csp"; version = "4.0.0"; sha256 = "1cwv8lqj8r15q81d2pz2jwzzbaji0l28xfrpw29kdpsaypm92z2q"; })
|
||||||
|
@ -161,7 +158,6 @@
|
||||||
(fetchNuGet { pname = "System.Security.Cryptography.Primitives"; version = "4.0.0"; sha256 = "0i7cfnwph9a10bm26m538h5xcr8b36jscp9sy1zhgifksxz4yixh"; })
|
(fetchNuGet { pname = "System.Security.Cryptography.Primitives"; version = "4.0.0"; sha256 = "0i7cfnwph9a10bm26m538h5xcr8b36jscp9sy1zhgifksxz4yixh"; })
|
||||||
(fetchNuGet { pname = "System.Security.Cryptography.X509Certificates"; version = "4.1.0"; sha256 = "0clg1bv55mfv5dq00m19cp634zx6inm31kf8ppbq1jgyjf2185dh"; })
|
(fetchNuGet { pname = "System.Security.Cryptography.X509Certificates"; version = "4.1.0"; sha256 = "0clg1bv55mfv5dq00m19cp634zx6inm31kf8ppbq1jgyjf2185dh"; })
|
||||||
(fetchNuGet { pname = "System.Security.Principal"; version = "4.0.1"; sha256 = "1nbzdfqvzzbgsfdd5qsh94d7dbg2v4sw0yx6himyn52zf8z6007p"; })
|
(fetchNuGet { pname = "System.Security.Principal"; version = "4.0.1"; sha256 = "1nbzdfqvzzbgsfdd5qsh94d7dbg2v4sw0yx6himyn52zf8z6007p"; })
|
||||||
(fetchNuGet { pname = "System.Security.Principal.Windows"; version = "4.7.0"; sha256 = "1a56ls5a9sr3ya0nr086sdpa9qv0abv31dd6fp27maqa9zclqq5d"; })
|
|
||||||
(fetchNuGet { pname = "System.Text.Encoding"; version = "4.0.11"; sha256 = "1dyqv0hijg265dwxg6l7aiv74102d6xjiwplh2ar1ly6xfaa4iiw"; })
|
(fetchNuGet { pname = "System.Text.Encoding"; version = "4.0.11"; sha256 = "1dyqv0hijg265dwxg6l7aiv74102d6xjiwplh2ar1ly6xfaa4iiw"; })
|
||||||
(fetchNuGet { pname = "System.Text.Encoding"; version = "4.3.0"; sha256 = "1f04lkir4iladpp51sdgmis9dj4y8v08cka0mbmsy0frc9a4gjqr"; })
|
(fetchNuGet { pname = "System.Text.Encoding"; version = "4.3.0"; sha256 = "1f04lkir4iladpp51sdgmis9dj4y8v08cka0mbmsy0frc9a4gjqr"; })
|
||||||
(fetchNuGet { pname = "System.Text.Encoding.CodePages"; version = "4.0.1"; sha256 = "00wpm3b9y0k996rm9whxprngm8l500ajmzgy2ip9pgwk0icp06y3"; })
|
(fetchNuGet { pname = "System.Text.Encoding.CodePages"; version = "4.0.1"; sha256 = "00wpm3b9y0k996rm9whxprngm8l500ajmzgy2ip9pgwk0icp06y3"; })
|
||||||
|
|
|
@ -1,20 +1,13 @@
|
||||||
{ lib, stdenv, fetchurl }:
|
{ lib, trivialBuild, fetchurl }:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
trivialBuild {
|
||||||
name = "control-lock";
|
pname = "control-lock";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "https://github.com/emacsmirror/emacswiki.org/blob/185fdc34fb1e02b43759ad933d3ee5646b0e78f8/control-lock.el";
|
url = "https://raw.githubusercontent.com/emacsmirror/emacswiki.org/185fdc34fb1e02b43759ad933d3ee5646b0e78f8/control-lock.el";
|
||||||
sha256 = "1b5xcgq2r565pr1c14dwrmn1fl05p56infapa5pqvajv2kpfla7h";
|
hash = "sha256-JCrmS3FSGDHSR+eAR0X/uO0nAgd3TUmFxwEVH5+KV+4=";
|
||||||
};
|
};
|
||||||
|
|
||||||
dontUnpack = true;
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
install -d $out/share/emacs/site-lisp
|
|
||||||
install $src $out/share/emacs/site-lisp/control-lock.el
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
description = "Like caps-lock, but for your control key. Give your pinky a rest!";
|
description = "Like caps-lock, but for your control key. Give your pinky a rest!";
|
||||||
homepage = "https://www.emacswiki.org/emacs/control-lock.el";
|
homepage = "https://www.emacswiki.org/emacs/control-lock.el";
|
||||||
|
|
|
@ -1,19 +1,17 @@
|
||||||
{ lib
|
{ trivialBuild
|
||||||
, trivial-build
|
|
||||||
, fetchurl
|
, fetchurl
|
||||||
}:
|
}:
|
||||||
|
|
||||||
trivial-build {
|
trivialBuild {
|
||||||
name = "perl-completion";
|
pname = "perl-completion";
|
||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "http://emacswiki.org/emacs/download/perl-completion.el";
|
url = "http://emacswiki.org/emacs/download/perl-completion.el";
|
||||||
sha256 = "0x6qsgs4hm87k0z9q3g4p6508kc3y123j5jayll3jf3lcl2vm6ks";
|
sha256 = "0x6qsgs4hm87k0z9q3g4p6508kc3y123j5jayll3jf3lcl2vm6ks";
|
||||||
};
|
};
|
||||||
|
|
||||||
dontUnpack = true;
|
|
||||||
|
|
||||||
meta = {
|
meta = {
|
||||||
|
broken = true;
|
||||||
description = "Minor mode provides useful features for editing perl codes";
|
description = "Minor mode provides useful features for editing perl codes";
|
||||||
homepage = "http://emacswiki.org/emacs/PerlCompletion";
|
homepage = "http://emacswiki.org/emacs/PerlCompletion";
|
||||||
};
|
};
|
||||||
|
|
|
@ -104,7 +104,7 @@ stdenv.mkDerivation rec {
|
||||||
webkitgtk_5_0
|
webkitgtk_5_0
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
dbus
|
dbus
|
||||||
xvfb-run
|
xvfb-run
|
||||||
];
|
];
|
||||||
|
|
|
@ -22,13 +22,13 @@
|
||||||
|
|
||||||
let
|
let
|
||||||
# when bumping the version, check if imhex has gotten support for the capstone version in nixpkgs
|
# when bumping the version, check if imhex has gotten support for the capstone version in nixpkgs
|
||||||
version = "1.19.3";
|
version = "1.26.2";
|
||||||
|
|
||||||
patterns_src = fetchFromGitHub {
|
patterns_src = fetchFromGitHub {
|
||||||
owner = "WerWolv";
|
owner = "WerWolv";
|
||||||
repo = "ImHex-Patterns";
|
repo = "ImHex-Patterns";
|
||||||
rev = "ImHex-v${version}";
|
rev = "ImHex-v${version}";
|
||||||
hash = "sha256-mukGPN2TugJZLLuZ5FTvZ4DxUsMGfVNhBFAPnBRC0qs=";
|
hash = "sha256-2+7bJzgwHfXcINM5oxwi3vEbUtq9gGJc/uxFOwT4RnM=";
|
||||||
};
|
};
|
||||||
|
|
||||||
in
|
in
|
||||||
|
@ -41,7 +41,7 @@ gcc12Stdenv.mkDerivation rec {
|
||||||
owner = "WerWolv";
|
owner = "WerWolv";
|
||||||
repo = pname;
|
repo = pname;
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
hash = "sha256-SFv5ulyjm5Yf+3Gpx+A74so2YClCJx1sx0LE5fh5eG4=";
|
hash = "sha256-H2bnRByCUAltngmVWgPW4vW8k5AWecOAzwtBKsjbpTw=";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake llvm python3 perl pkg-config ];
|
nativeBuildInputs = [ cmake llvm python3 perl pkg-config ];
|
||||||
|
@ -72,10 +72,8 @@ gcc12Stdenv.mkDerivation rec {
|
||||||
"-DUSE_SYSTEM_YARA=ON"
|
"-DUSE_SYSTEM_YARA=ON"
|
||||||
];
|
];
|
||||||
|
|
||||||
# for reasons unknown, the built-in plugin isn't found unless made available under $out/bin
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
ln -s $out/share/imhex/plugins $out/bin/
|
mkdir -p $out/share/imhex
|
||||||
|
|
||||||
for d in ${patterns_src}/{constants,encodings,includes,magic,patterns}; do
|
for d in ${patterns_src}/{constants,encodings,includes,magic,patterns}; do
|
||||||
cp -r $d $out/share/imhex/
|
cp -r $d $out/share/imhex/
|
||||||
done
|
done
|
||||||
|
|
|
@ -96,7 +96,7 @@ in
|
||||||
];
|
];
|
||||||
|
|
||||||
# extra programs test via `make functionaltest`
|
# extra programs test via `make functionaltest`
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
fish
|
fish
|
||||||
nodejs
|
nodejs
|
||||||
pyEnv # for src/clint.py
|
pyEnv # for src/clint.py
|
||||||
|
|
|
@ -30,7 +30,7 @@ with python3.pkgs; buildPythonApplication rec {
|
||||||
setuptools
|
setuptools
|
||||||
];
|
];
|
||||||
|
|
||||||
checkInputs = [
|
nativeCheckInputs = [
|
||||||
neovim
|
neovim
|
||||||
pytestCheckHook
|
pytestCheckHook
|
||||||
];
|
];
|
||||||
|
|
|
@ -2,13 +2,13 @@
|
||||||
|
|
||||||
mkDerivation rec {
|
mkDerivation rec {
|
||||||
pname = "notepad-next";
|
pname = "notepad-next";
|
||||||
version = "0.5.6";
|
version = "0.6";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "dail8859";
|
owner = "dail8859";
|
||||||
repo = "NotepadNext";
|
repo = "NotepadNext";
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
sha256 = "sha256-0ZmyEtyVpqQ05FOYdFbnFqfPJKNkrweflSl+irOzcuk=";
|
sha256 = "sha256-t+TfyhQjUp4xJQ4vihAwm691dpt8ctQwLYDRRAQI7OM=";
|
||||||
# External dependencies - https://github.com/dail8859/NotepadNext/issues/135
|
# External dependencies - https://github.com/dail8859/NotepadNext/issues/135
|
||||||
fetchSubmodules = true;
|
fetchSubmodules = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,25 +1,29 @@
|
||||||
{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles, makeWrapper, pkg-config
|
{ lib, stdenv, buildGoModule, fetchFromGitHub, installShellFiles, makeWrapper, pkg-config
|
||||||
, tcsh
|
, withGui ? true, vte
|
||||||
, withGui ? stdenv.isLinux, vte # vte is broken on darwin
|
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildGoModule rec {
|
buildGoModule rec {
|
||||||
pname = "o";
|
pname = "o";
|
||||||
version = "2.57.0";
|
version = "2.58.0";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "xyproto";
|
owner = "xyproto";
|
||||||
repo = "o";
|
repo = "o";
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
hash = "sha256-UKFquf5h1e7gRAZgtcTdEpoNv+TOC8BYb2ED26X274s=";
|
hash = "sha256-oYWlciTQ/4mm/gTSQEkD/xPeLfDjIAMksjj1DVodZW4=";
|
||||||
};
|
};
|
||||||
|
|
||||||
postPatch = ''
|
|
||||||
substituteInPlace ko/main.cpp --replace '/bin/csh' '${tcsh}/bin/tcsh'
|
|
||||||
'';
|
|
||||||
|
|
||||||
vendorSha256 = null;
|
vendorSha256 = null;
|
||||||
|
|
||||||
|
postPatch = lib.optionalString stdenv.isDarwin ''
|
||||||
|
substituteInPlace Makefile \
|
||||||
|
--replace "-Wl,--as-needed" ""
|
||||||
|
|
||||||
|
# Requires impure pbcopy and pbpaste
|
||||||
|
substituteInPlace v2/pbcopy_test.go \
|
||||||
|
--replace TestPBcopy SkipTestPBcopy
|
||||||
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [ installShellFiles makeWrapper pkg-config ];
|
nativeBuildInputs = [ installShellFiles makeWrapper pkg-config ];
|
||||||
|
|
||||||
buildInputs = lib.optional withGui vte;
|
buildInputs = lib.optional withGui vte;
|
||||||
|
@ -31,7 +35,7 @@ buildGoModule rec {
|
||||||
installManPage o.1
|
installManPage o.1
|
||||||
'' + lib.optionalString withGui ''
|
'' + lib.optionalString withGui ''
|
||||||
make install-gui PREFIX=$out
|
make install-gui PREFIX=$out
|
||||||
wrapProgram $out/bin/ko --prefix PATH : $out/bin
|
wrapProgram $out/bin/og --prefix PATH : $out/bin
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
|
|
|
@ -20,14 +20,14 @@ let
|
||||||
version = "6.8";
|
version = "6.8";
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "https://download.pinegrow.com/PinegrowLinux64.${versions."6".version}.zip";
|
url = "https://download.pinegrow.com/PinegrowLinux64.${versions."6".version}.zip";
|
||||||
sha256 = "sha256-gqRmu0VR8Aj57UwYYLKICd4FnYZMhM6pTTSGIY5MLMk=";
|
hash = "sha256-gqRmu0VR8Aj57UwYYLKICd4FnYZMhM6pTTSGIY5MLMk=";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
"7" = {
|
"7" = {
|
||||||
version = "7.03";
|
version = "7.05.2";
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "https://download.pinegrow.com/PinegrowLinux64.${versions."7".version}.zip";
|
url = "https://github.com/Pinegrow/PinegrowReleases/releases/download/pg${builtins.substring 0 4 (versions."7".version)}/PinegrowLinux64.${versions."7".version}.zip";
|
||||||
sha256 = "sha256-MdaJBmOPr1+J235IZPd3EBzbDTiORginyVKsjSkKbpE=";
|
hash = "sha256-Cvy4JwnQHMp7K0mKtIH8lk1bZ9hwa8nvtmimBK0UAf8=";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -73,7 +73,7 @@ in stdenv.mkDerivation rec {
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
doCheck = !isCross;
|
doCheck = !isCross;
|
||||||
checkInputs = lib.optionals (!isCross) [ dejagnu ];
|
nativeCheckInputs = lib.optionals (!isCross) [ dejagnu ];
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
moveToOutput share/emacs "$out"
|
moveToOutput share/emacs "$out"
|
||||||
|
|
|
@ -1,26 +1,14 @@
|
||||||
{ lib, stdenv, appimageTools, autoPatchelfHook, desktop-file-utils
|
{ callPackage, lib, stdenv, appimageTools, autoPatchelfHook, desktop-file-utils
|
||||||
, fetchurl, libsecret }:
|
, fetchurl, libsecret }:
|
||||||
|
|
||||||
let
|
let
|
||||||
version = "3.23.69";
|
srcjson = builtins.fromJSON (builtins.readFile ./src.json);
|
||||||
|
version = srcjson.version;
|
||||||
pname = "standardnotes";
|
pname = "standardnotes";
|
||||||
name = "${pname}-${version}";
|
name = "${pname}-${version}";
|
||||||
throwSystem = throw "Unsupported system: ${stdenv.hostPlatform.system}";
|
throwSystem = throw "Unsupported system: ${stdenv.hostPlatform.system}";
|
||||||
|
|
||||||
plat = {
|
src = fetchurl (srcjson.appimage.${stdenv.hostPlatform.system} or throwSystem);
|
||||||
i686-linux = "i386";
|
|
||||||
x86_64-linux = "x86_64";
|
|
||||||
}.${stdenv.hostPlatform.system} or throwSystem;
|
|
||||||
|
|
||||||
sha256 = {
|
|
||||||
i686-linux = "sha256-/A2LjV8ky20bcKgs0ijwldryi5VkyROwz49vWYXYQus=";
|
|
||||||
x86_64-linux = "sha256-fA9WH9qUtvAHF9hTFRtxQdpz2dpK0joD0zX9VYBo10g=";
|
|
||||||
}.${stdenv.hostPlatform.system} or throwSystem;
|
|
||||||
|
|
||||||
src = fetchurl {
|
|
||||||
url = "https://github.com/standardnotes/app/releases/download/%40standardnotes%2Fdesktop%40${version}/standard-notes-${version}-linux-${plat}.AppImage";
|
|
||||||
inherit sha256;
|
|
||||||
};
|
|
||||||
|
|
||||||
appimageContents = appimageTools.extract {
|
appimageContents = appimageTools.extract {
|
||||||
inherit name src;
|
inherit name src;
|
||||||
|
@ -47,6 +35,8 @@ in appimageTools.wrapType2 rec {
|
||||||
ln -s ${appimageContents}/usr/share/icons share
|
ln -s ${appimageContents}/usr/share/icons share
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
passthru.updateScript = callPackage ./update.nix {};
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "A simple and private notes app";
|
description = "A simple and private notes app";
|
||||||
longDescription = ''
|
longDescription = ''
|
||||||
|
@ -55,8 +45,8 @@ in appimageTools.wrapType2 rec {
|
||||||
'';
|
'';
|
||||||
homepage = "https://standardnotes.org";
|
homepage = "https://standardnotes.org";
|
||||||
license = licenses.agpl3;
|
license = licenses.agpl3;
|
||||||
maintainers = with maintainers; [ mgregoire chuangzhu ];
|
maintainers = with maintainers; [ mgregoire chuangzhu squalus ];
|
||||||
sourceProvenance = [ sourceTypes.binaryNativeCode ];
|
sourceProvenance = [ sourceTypes.binaryNativeCode ];
|
||||||
platforms = [ "i686-linux" "x86_64-linux" ];
|
platforms = builtins.attrNames srcjson.appimage;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
17
pkgs/applications/editors/standardnotes/src.json
Normal file
17
pkgs/applications/editors/standardnotes/src.json
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
{
|
||||||
|
"version": "3.129.0",
|
||||||
|
"appimage": {
|
||||||
|
"x86_64-linux": {
|
||||||
|
"url": "https://github.com/standardnotes/app/releases/download/%40standardnotes/desktop%403.129.0/standard-notes-3.129.0-linux-x86_64.AppImage",
|
||||||
|
"hash": "sha512-JLO2jX9Us6BjqmTZIkVyxy2pqFM/eFGpwi6vXicMOgDB0UsgEMTK+Ww+9g+vJ1KbFRFmlt187qkdSNcevQPt7w=="
|
||||||
|
},
|
||||||
|
"aarch64-linux": {
|
||||||
|
"url": "https://github.com/standardnotes/app/releases/download/%40standardnotes/desktop%403.129.0/standard-notes-3.129.0-linux-arm64.AppImage",
|
||||||
|
"hash": "sha512-LGUSRqMrJ+hVHyi/bjI/NkWRVsmY0Kh/wRY9RNJXm0C3dKQSFV8ca4GeY9+VCuJEecR4LGnWp4agS5jPybPP6w=="
|
||||||
|
},
|
||||||
|
"i686-linux": {
|
||||||
|
"url": "https://github.com/standardnotes/app/releases/download/%40standardnotes/desktop%403.129.0/standard-notes-3.129.0-linux-i386.AppImage",
|
||||||
|
"hash": "sha512-XbQ4hn3QJ61hDC12cK95zsUowbyXPYArHZoRDx5trQ30phtQxtz6nV+pL00m4S9kYeEhsAwk1wXlRq9Ylbz2IA=="
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
55
pkgs/applications/editors/standardnotes/update.nix
Normal file
55
pkgs/applications/editors/standardnotes/update.nix
Normal file
|
@ -0,0 +1,55 @@
|
||||||
|
{ writeScript
|
||||||
|
, lib, curl, runtimeShell, jq, coreutils, moreutils, nix, gnused }:
|
||||||
|
|
||||||
|
writeScript "update-standardnotes" ''
|
||||||
|
#!${runtimeShell}
|
||||||
|
PATH=${lib.makeBinPath [ jq curl nix coreutils moreutils gnused ]}
|
||||||
|
|
||||||
|
set -euo pipefail
|
||||||
|
set -x
|
||||||
|
|
||||||
|
tmpDir=$(mktemp -d)
|
||||||
|
srcJson=pkgs/applications/editors/standardnotes/src.json
|
||||||
|
jsonPath="$tmpDir"/latest
|
||||||
|
|
||||||
|
oldVersion=$(jq -r .version < "$srcJson")
|
||||||
|
|
||||||
|
curl https://api.github.com/repos/standardnotes/app/releases/latest > "$jsonPath"
|
||||||
|
|
||||||
|
tagName=$(jq -r .tag_name < "$jsonPath")
|
||||||
|
|
||||||
|
if [[ ! "$tagName" =~ "desktop" ]]; then
|
||||||
|
echo "latest release '$tagName' not a desktop release"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
newVersion=$(jq -r .tag_name < "$jsonPath" | sed s,@standardnotes/desktop@,,g)
|
||||||
|
|
||||||
|
if [[ "$oldVersion" == "$newVersion" ]]; then
|
||||||
|
echo "version did not change"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
function getDownloadUrl() {
|
||||||
|
jq -r ".assets[] | select(.name==\"standard-notes-$newVersion-$1.AppImage\") | .browser_download_url" < "$jsonPath"
|
||||||
|
}
|
||||||
|
|
||||||
|
function setJsonKey() {
|
||||||
|
jq "$1 = \"$2\"" "$srcJson" | sponge "$srcJson"
|
||||||
|
}
|
||||||
|
|
||||||
|
function updatePlatform() {
|
||||||
|
nixPlatform="$1"
|
||||||
|
upstreamPlatform="$2"
|
||||||
|
url=$(getDownloadUrl "$upstreamPlatform")
|
||||||
|
hash=$(nix-prefetch-url "$url" --type sha512)
|
||||||
|
sriHash=$(nix hash to-sri --type sha512 $hash)
|
||||||
|
setJsonKey .appimage[\""$nixPlatform"\"].url "$url"
|
||||||
|
setJsonKey .appimage[\""$nixPlatform"\"].hash "$sriHash"
|
||||||
|
}
|
||||||
|
|
||||||
|
updatePlatform x86_64-linux linux-x86_64
|
||||||
|
updatePlatform aarch64-linux linux-arm64
|
||||||
|
updatePlatform i686-linux linux-i386
|
||||||
|
setJsonKey .version "$newVersion"
|
||||||
|
''
|
File diff suppressed because it is too large
Load diff
|
@ -1,6 +1,6 @@
|
||||||
# generated by pkgs/applications/editors/vim/plugins/nvim-treesitter/update.py
|
# generated by pkgs/applications/editors/vim/plugins/nvim-treesitter/update.py
|
||||||
|
|
||||||
{ buildGrammar, fetchFromBitbucket, fetchFromGitHub, fetchFromGitLab, fetchFromGitea, fetchFromGitiles, fetchFromRepoOrCz, fetchFromSourcehut, fetchgit, fetchhg, fetchsvn }:
|
{ buildGrammar, fetchCrate, fetchFromBitbucket, fetchFromGitHub, fetchFromGitLab, fetchFromGitea, fetchFromGitiles, fetchFromRepoOrCz, fetchFromSourcehut, fetchHex, fetchgit, fetchhg, fetchsvn }:
|
||||||
|
|
||||||
{
|
{
|
||||||
ada = buildGrammar {
|
ada = buildGrammar {
|
||||||
|
@ -115,12 +115,12 @@
|
||||||
};
|
};
|
||||||
c_sharp = buildGrammar {
|
c_sharp = buildGrammar {
|
||||||
language = "c_sharp";
|
language = "c_sharp";
|
||||||
version = "3b661ce";
|
version = "2574501";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "tree-sitter";
|
owner = "tree-sitter";
|
||||||
repo = "tree-sitter-c-sharp";
|
repo = "tree-sitter-c-sharp";
|
||||||
rev = "3b661ced8d510aa424e2f68314520c281dd8c113";
|
rev = "2574501b475b7ba7bc10d08dd1ff9732d3769662";
|
||||||
hash = "sha256-Z+ueKX2CAtWTCMipElZUl97hrUEb8Dv1po8xSLI3iJA=";
|
hash = "sha256-bXwGZJ+lYTJyaD7kbQGL6hagpkgqqCsPHBiz9AOXfNc=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/tree-sitter/tree-sitter-c-sharp";
|
meta.homepage = "https://github.com/tree-sitter/tree-sitter-c-sharp";
|
||||||
};
|
};
|
||||||
|
@ -402,6 +402,17 @@
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/stadelmanma/tree-sitter-fortran";
|
meta.homepage = "https://github.com/stadelmanma/tree-sitter-fortran";
|
||||||
};
|
};
|
||||||
|
fsh = buildGrammar {
|
||||||
|
language = "fsh";
|
||||||
|
version = "fa33477";
|
||||||
|
source = fetchFromGitHub {
|
||||||
|
owner = "mgramigna";
|
||||||
|
repo = "tree-sitter-fsh";
|
||||||
|
rev = "fa3347712f7a59ed02ccf508284554689c6cde28";
|
||||||
|
hash = "sha256-6TLG2edQeo+jRVAnO6mq3pC8RYNFi2UVVT3mQGZqk5U=";
|
||||||
|
};
|
||||||
|
meta.homepage = "https://github.com/mgramigna/tree-sitter-fsh";
|
||||||
|
};
|
||||||
fusion = buildGrammar {
|
fusion = buildGrammar {
|
||||||
language = "fusion";
|
language = "fusion";
|
||||||
version = "19db2f4";
|
version = "19db2f4";
|
||||||
|
@ -448,12 +459,12 @@
|
||||||
};
|
};
|
||||||
gitcommit = buildGrammar {
|
gitcommit = buildGrammar {
|
||||||
language = "gitcommit";
|
language = "gitcommit";
|
||||||
version = "0ef7dd0";
|
version = "190d288";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "gbprod";
|
owner = "gbprod";
|
||||||
repo = "tree-sitter-gitcommit";
|
repo = "tree-sitter-gitcommit";
|
||||||
rev = "0ef7dd07236141a878b4cc2c488375baa5cc9d5d";
|
rev = "190d288a1746bddb4abe96b597fb7d17b76e5522";
|
||||||
hash = "sha256-8OyjmnCLR14ivJBf/9KO4rmc99xL818iMY8uxkjtVGw=";
|
hash = "sha256-PPdwdUfJ+2TCxVdEvexxGSBMDZmI1GW7eSfc/X3Me7Y=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/gbprod/tree-sitter-gitcommit";
|
meta.homepage = "https://github.com/gbprod/tree-sitter-gitcommit";
|
||||||
};
|
};
|
||||||
|
@ -482,12 +493,12 @@
|
||||||
};
|
};
|
||||||
glimmer = buildGrammar {
|
glimmer = buildGrammar {
|
||||||
language = "glimmer";
|
language = "glimmer";
|
||||||
version = "fee3427";
|
version = "c0bfd26";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "alexlafroscia";
|
owner = "alexlafroscia";
|
||||||
repo = "tree-sitter-glimmer";
|
repo = "tree-sitter-glimmer";
|
||||||
rev = "fee34278dc212869dcfc92fce3007ee79a752867";
|
rev = "c0bfd260cdcbe2976f4633547c218f09f7222a89";
|
||||||
hash = "sha256-a3goK+QSkrdsKvimT8vpsJ1bt8FhLf1bws0aqjncv3A=";
|
hash = "sha256-Goj900MJxO44KYkzD0UpGFEGHAwr6qhe2bmCzpx5BhE=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/alexlafroscia/tree-sitter-glimmer";
|
meta.homepage = "https://github.com/alexlafroscia/tree-sitter-glimmer";
|
||||||
};
|
};
|
||||||
|
@ -903,23 +914,23 @@
|
||||||
};
|
};
|
||||||
meson = buildGrammar {
|
meson = buildGrammar {
|
||||||
language = "meson";
|
language = "meson";
|
||||||
version = "6c5f7ef";
|
version = "5f3138d";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "Decodetalkers";
|
owner = "Decodetalkers";
|
||||||
repo = "tree-sitter-meson";
|
repo = "tree-sitter-meson";
|
||||||
rev = "6c5f7ef944f9c6ae8a0fc28b9071a4b493652238";
|
rev = "5f3138d555aceef976ec9a1d4a3f78e13b31e45f";
|
||||||
hash = "sha256-r/H7v6a1blsendVBxx9Qy4f2i4V3LsxSwe+9/PRbfG8=";
|
hash = "sha256-P0S2JpRjAznDLaU97NMzLuuNyPqqy4RNqBa+PKvyl6s=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/Decodetalkers/tree-sitter-meson";
|
meta.homepage = "https://github.com/Decodetalkers/tree-sitter-meson";
|
||||||
};
|
};
|
||||||
nickel = buildGrammar {
|
nickel = buildGrammar {
|
||||||
language = "nickel";
|
language = "nickel";
|
||||||
version = "7867780";
|
version = "092e901";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "nickel-lang";
|
owner = "nickel-lang";
|
||||||
repo = "tree-sitter-nickel";
|
repo = "tree-sitter-nickel";
|
||||||
rev = "7867780e52ebeda0daa4a55acb870100e070d274";
|
rev = "092e90142667482996880044d2c04837d3d1c266";
|
||||||
hash = "sha256-SXM15LbQ4bGKx+2QY7jMHq4G4ATtak2Umnb3SHFUqM0=";
|
hash = "sha256-y0Lx6HdkoC7rOzm8fOfLBUt6672qe7AHe1SI6YY/aHE=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/nickel-lang/tree-sitter-nickel";
|
meta.homepage = "https://github.com/nickel-lang/tree-sitter-nickel";
|
||||||
};
|
};
|
||||||
|
@ -1082,12 +1093,12 @@
|
||||||
};
|
};
|
||||||
pug = buildGrammar {
|
pug = buildGrammar {
|
||||||
language = "pug";
|
language = "pug";
|
||||||
version = "63e2149";
|
version = "148608f";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "zealot128";
|
owner = "zealot128";
|
||||||
repo = "tree-sitter-pug";
|
repo = "tree-sitter-pug";
|
||||||
rev = "63e214905970e75f065688b1e8aa90823c3aacdc";
|
rev = "148608f3a88708829ac4e79ff9cb1c4a618e01b7";
|
||||||
hash = "sha256-t/KRUV1DMlU/xu5BRe1VZm+dliXdtUVhFO+6psiHf+Q=";
|
hash = "sha256-wEUJdu+2deObsc54BNPdUyTAR9Eih8hGbWRrwP5bhMk=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/zealot128/tree-sitter-pug";
|
meta.homepage = "https://github.com/zealot128/tree-sitter-pug";
|
||||||
};
|
};
|
||||||
|
@ -1236,23 +1247,23 @@
|
||||||
};
|
};
|
||||||
scala = buildGrammar {
|
scala = buildGrammar {
|
||||||
language = "scala";
|
language = "scala";
|
||||||
version = "fd05f09";
|
version = "f6bbf35";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "tree-sitter";
|
owner = "tree-sitter";
|
||||||
repo = "tree-sitter-scala";
|
repo = "tree-sitter-scala";
|
||||||
rev = "fd05f09043051c82fba695aa95cee9c534fbc533";
|
rev = "f6bbf35de41653b409ca9a3537a154f2b095ef64";
|
||||||
hash = "sha256-/o9TsnKGeukIGgfOjwNDjdxPkr5zyIPh1bZsvr2FX90=";
|
hash = "sha256-GNGD5UIPzpRQbGCp/fcBV6laPRhU5YQGbNiaAGis0CY=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/tree-sitter/tree-sitter-scala";
|
meta.homepage = "https://github.com/tree-sitter/tree-sitter-scala";
|
||||||
};
|
};
|
||||||
scheme = buildGrammar {
|
scheme = buildGrammar {
|
||||||
language = "scheme";
|
language = "scheme";
|
||||||
version = "16bdcf0";
|
version = "67b90a3";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "6cdh";
|
owner = "6cdh";
|
||||||
repo = "tree-sitter-scheme";
|
repo = "tree-sitter-scheme";
|
||||||
rev = "16bdcf0495865e17ae5b995257458e31e8b7f450";
|
rev = "67b90a365bebf4406af4e5a546d6336de787e135";
|
||||||
hash = "sha256-+K+T5IgcEdTZK4s60AmkPg7L6Aw0mj36FMsWaRxUT0I=";
|
hash = "sha256-aHYOzOPK74Jd6MWFsap/k+dG+aJDTXQ05q7NoP5kfd8=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/6cdh/tree-sitter-scheme";
|
meta.homepage = "https://github.com/6cdh/tree-sitter-scheme";
|
||||||
};
|
};
|
||||||
|
@ -1313,12 +1324,12 @@
|
||||||
};
|
};
|
||||||
sql = buildGrammar {
|
sql = buildGrammar {
|
||||||
language = "sql";
|
language = "sql";
|
||||||
version = "3647b9f";
|
version = "9d98029";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "derekstride";
|
owner = "derekstride";
|
||||||
repo = "tree-sitter-sql";
|
repo = "tree-sitter-sql";
|
||||||
rev = "3647b9f5b937269f43ac6e4b6ebcb6f52e033c17";
|
rev = "9d9802991aa1d1bc00eee7713a838dab1eb4f149";
|
||||||
hash = "sha256-flZtgmMflDlWggMisUfVOA7ikGpkYwAGxzlc4jYzrrQ=";
|
hash = "sha256-Iy5rqNZem1r++aI7vGITzBSFGjdDLGHFOgBWqIgKZX0=";
|
||||||
};
|
};
|
||||||
generate = true;
|
generate = true;
|
||||||
meta.homepage = "https://github.com/derekstride/tree-sitter-sql";
|
meta.homepage = "https://github.com/derekstride/tree-sitter-sql";
|
||||||
|
@ -1358,12 +1369,12 @@
|
||||||
};
|
};
|
||||||
swift = buildGrammar {
|
swift = buildGrammar {
|
||||||
language = "swift";
|
language = "swift";
|
||||||
version = "5f0ffaf";
|
version = "0fe0de5";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "alex-pinkus";
|
owner = "alex-pinkus";
|
||||||
repo = "tree-sitter-swift";
|
repo = "tree-sitter-swift";
|
||||||
rev = "5f0ffaf21c7fda4d758d9ef5b20d563271653ce0";
|
rev = "0fe0de56b528cbf24a654c734ca181b48be3831d";
|
||||||
hash = "sha256-tPcCa3hqWN2NuQZOJXnB10h0m1MzRL4M+dvrtlpkAGs=";
|
hash = "sha256-tU6UTyTR5biS6qBG0z6NbjJQUtZItzzscAKftUAzLq0=";
|
||||||
};
|
};
|
||||||
generate = true;
|
generate = true;
|
||||||
meta.homepage = "https://github.com/alex-pinkus/tree-sitter-swift";
|
meta.homepage = "https://github.com/alex-pinkus/tree-sitter-swift";
|
||||||
|
@ -1428,12 +1439,12 @@
|
||||||
};
|
};
|
||||||
tlaplus = buildGrammar {
|
tlaplus = buildGrammar {
|
||||||
language = "tlaplus";
|
language = "tlaplus";
|
||||||
version = "f2ad727";
|
version = "7c5452a";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "tlaplus-community";
|
owner = "tlaplus-community";
|
||||||
repo = "tree-sitter-tlaplus";
|
repo = "tree-sitter-tlaplus";
|
||||||
rev = "f2ad7272d145598ff2d27fda15379d26aa33a7e1";
|
rev = "7c5452a0720271a349d6174b8778e76b189bebef";
|
||||||
hash = "sha256-lnl0q9vJiIoqU3Lo+uCIcMdMueXTQ/MVgZUCHvXeqhs=";
|
hash = "sha256-DJIA2gvwWWqTGrC48FZiRZNt048KiQ/4sZxYSnHmlEg=";
|
||||||
};
|
};
|
||||||
meta.homepage = "https://github.com/tlaplus-community/tree-sitter-tlaplus";
|
meta.homepage = "https://github.com/tlaplus-community/tree-sitter-tlaplus";
|
||||||
};
|
};
|
||||||
|
@ -1507,12 +1518,12 @@
|
||||||
};
|
};
|
||||||
v = buildGrammar {
|
v = buildGrammar {
|
||||||
language = "v";
|
language = "v";
|
||||||
version = "497563e";
|
version = "0b03983";
|
||||||
source = fetchFromGitHub {
|
source = fetchFromGitHub {
|
||||||
owner = "vlang";
|
owner = "vlang";
|
||||||
repo = "vls";
|
repo = "vls";
|
||||||
rev = "497563e140bf17d73f28e20b5a65e72740c2dc65";
|
rev = "0b039830a33e759f0c9ee978b47ad10b82d37349";
|
||||||
hash = "sha256-2AU/QGAroq5NReGhCbSJkAnGvftubtCG4hnnBjPKbdY=";
|
hash = "sha256-sQxq/tWNN/aWD3ZmNhil45cnjzfy/2AXn2X/NhzvnKk=";
|
||||||
};
|
};
|
||||||
location = "tree_sitter_v";
|
location = "tree_sitter_v";
|
||||||
meta.homepage = "https://github.com/vlang/vls";
|
meta.homepage = "https://github.com/vlang/vls";
|
||||||
|
|
|
@ -1052,7 +1052,7 @@ self: super: {
|
||||||
libiconv
|
libiconv
|
||||||
];
|
];
|
||||||
|
|
||||||
cargoSha256 = "sha256-ls4WZQees78SNJilXoL3CSXAaILxX1/WUMCyO7+14IM=";
|
cargoSha256 = "sha256-v9RXW5RSPMotRVR/9ljBJ9VNbrLnSkU3zlEU79Xem28=";
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
''
|
''
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue