1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-07 10:11:47 +02:00

Format .nix files

This does not include any automation for the release branch, but
is based on the configuration of https://github.com/NixOS/nix/pull/12349

    pre-commit run -a nixfmt-rfc-style
This commit is contained in:
Robert Hensing 2025-01-24 20:40:21 +01:00
parent 6cb17fd836
commit 32aed360b8
266 changed files with 7443 additions and 5118 deletions

View file

@ -10,10 +10,13 @@ let
lt = builtins.sub 0 1;
gt = 1;
versionTest = v1: v2: expected:
let d1 = builtins.compareVersions v1 v2;
d2 = builtins.compareVersions v2 v1;
in d1 == builtins.sub 0 d2 && d1 == expected;
versionTest =
v1: v2: expected:
let
d1 = builtins.compareVersions v1 v2;
d2 = builtins.compareVersions v2 v1;
in
d1 == builtins.sub 0 d2 && d1 == expected;
tests = [
((builtins.parseDrvName name1).name == "hello")
@ -40,4 +43,5 @@ let
(versionTest "2.3pre1" "2.3q" lt)
];
in (import ./lib.nix).and tests
in
(import ./lib.nix).and tests