Skip to content
Snippets Groups Projects
Commit 73857b7b authored by Daniel Firth's avatar Daniel Firth Committed by Daniel Firth
Browse files

Update lint-utils

parent 58000f42
Branches
No related merge requests found
stages: stages:
- generate - generate
- eval
- check - check
- impure
generate-flake-ci: generate-flake-ci:
stage: generate stage: generate
script: nix run ".#horizon-gen-gitlab-ci" > flake-ci.yml script: nix run "git+https://gitlab.homotopic.tech/haskell/flake-to-gitlab-ci" > flake-ci.yml
artifacts: artifacts:
paths: paths:
- flake-ci.yml - flake-ci.yml
eval-flake:
stage: eval
script: nix flake show
flake-ci: flake-ci:
stage: check stage: check
trigger: trigger:
...@@ -21,3 +17,8 @@ flake-ci: ...@@ -21,3 +17,8 @@ flake-ci:
- artifact: flake-ci.yml - artifact: flake-ci.yml
job: generate-flake-ci job: generate-flake-ci
strategy: depend strategy: depend
impure-tests:
stage: impure
script:
- nix run .#run-impure-tests
...@@ -67,11 +67,11 @@ ...@@ -67,11 +67,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1655192403, "lastModified": 1669815989,
"narHash": "sha256-XyKDvRGDh8VXA6zN8DUTnDaTMrk0MxMKg70MaAX1A2Y=", "narHash": "sha256-yDE8uxa/O633VeRBlJKSY5q9JtzoBoMANvgupdI42YI=",
"ref": "refs/heads/master", "ref": "refs/heads/master",
"rev": "a7ae54afdc4c05a5aabf202d5a76d02705eb6147", "rev": "5b97bd76dd6756dfc29a32d25a5c78c0522bac10",
"revCount": 28, "revCount": 39,
"type": "git", "type": "git",
"url": "https://gitlab.homotopic.tech/nix/lint-utils" "url": "https://gitlab.homotopic.tech/nix/lint-utils"
}, },
......
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
in in
with pkgs.lib; with pkgs.lib;
with pkgs.writers; with pkgs.writers;
with lint-utils.writers.${system};
let let
horizon-gen-nix-app = get-flake horizon-gen-nix; horizon-gen-nix-app = get-flake horizon-gen-nix;
...@@ -52,12 +53,12 @@ ...@@ -52,12 +53,12 @@
horizon-gen-gitlab-ci = writeBashBin "gen-gitlab-ci" "${pkgs.dhall-json}/bin/dhall-to-yaml --file .gitlab-ci.dhall"; horizon-gen-gitlab-ci = writeBashBin "gen-gitlab-ci" "${pkgs.dhall-json}/bin/dhall-to-yaml --file .gitlab-ci.dhall";
run-impure-tests = lint-utils.writers.writePorcelainOrDieBin { run-impure-tests = writePorcelainOrDieBin {
name = "run-impure-tests"; name = "run-impure-tests";
src = ./.; src = ./.;
command = '' command = ''
export PATH=$PATH:${pkgs.nix-prefetch-git}/bin:${pkgs.cabal-install}/bin
cabal update cabal update
export PATH=$PATH:${pkgs.nix-prefetch-git}/bin
rm pkgs -rf && nix run .#horizon-gen-nix make-package-set; rm pkgs -rf && nix run .#horizon-gen-nix make-package-set;
nixpkgs-fmt pkgs/* nixpkgs-fmt pkgs/*
''; '';
...@@ -81,11 +82,12 @@ ...@@ -81,11 +82,12 @@
program = "${horizon-gen-gitlab-ci}/bin/gen-gitlab-ci"; program = "${horizon-gen-gitlab-ci}/bin/gen-gitlab-ci";
}; };
run-impure-tests = run-impure-tests-app;
}; };
checks = { checks = {
dhall-format = lint-utils.outputs.linters.${system}.dhall-format ./.; dhall-format = lint-utils.outputs.linters.${system}.dhall-format { src = ./. };
nixpkgs-fmt = lint-utils.outputs.linters.${system}.nixpkgs-fmt ./.; nixpkgs-fmt = lint-utils.outputs.linters.${system}.nixpkgs-fmt { src = ./. };
}; };
inherit legacyPackages; inherit legacyPackages;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment