mirror of
https://github.com/nix-community/dream2nix.git
synced 2024-12-23 14:31:55 +03:00
ci: remove ./ci.nix
This commit is contained in:
parent
4eb5478fdd
commit
e913ec992b
24
ci.nix
24
ci.nix
@ -1,24 +0,0 @@
|
||||
let
|
||||
b = builtins;
|
||||
flakeCompatSrc = b.fetchurl "https://raw.githubusercontent.com/edolstra/flake-compat/12c64ca55c1014cdc1b16ed5a804aa8576601ff2/default.nix";
|
||||
flake = (import flakeCompatSrc {src = ./.;}).defaultNix;
|
||||
pkgs = import flake.inputs.nixpkgs {};
|
||||
recurseIntoAll = b.mapAttrs (name: val: pkgs.recurseIntoAttrs val);
|
||||
|
||||
dream2nix-repo = import ./examples/dream2nix-repo {
|
||||
dream2nixSource = ./.;
|
||||
inherit pkgs;
|
||||
};
|
||||
|
||||
dream2nix-repo-flake = (import ./examples/dream2nix-repo-flake/flake.nix).outputs {
|
||||
self = dream2nix-repo-flake;
|
||||
dream2nix = flake;
|
||||
nixpkgs = flake.inputs.nixpkgs;
|
||||
};
|
||||
in
|
||||
recurseIntoAll {
|
||||
inherit dream2nix-repo dream2nix-repo-flake;
|
||||
checks = flake.checks.x86_64-linux;
|
||||
devShells = flake.devShells.x86_64-linux;
|
||||
packages = flake.packages.x86_64-linux;
|
||||
}
|
@ -80,14 +80,17 @@
|
||||
dream2nix-shell = mkShell {
|
||||
devshell.name = "dream2nix-devshell";
|
||||
|
||||
packages = [
|
||||
packages =
|
||||
[
|
||||
pkgs.alejandra
|
||||
pkgs.mdbook
|
||||
inputs'.nix-unit.packages.nix-unit
|
||||
(pkgs.python3.withPackages (ps: [
|
||||
pkgs.python3.pkgs.black
|
||||
]))
|
||||
];
|
||||
]
|
||||
++ (l.optionals pkgs.stdenv.isLinux [
|
||||
inputs'.nix-unit.packages.nix-unit
|
||||
]);
|
||||
|
||||
commands =
|
||||
[
|
||||
|
@ -3,8 +3,11 @@
|
||||
perSystem = {
|
||||
pkgs,
|
||||
inputs',
|
||||
lib,
|
||||
system,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
lib.optionalAttrs (system == "x86_64-linux") {
|
||||
# map all modules in /examples to a package output in the flake.
|
||||
checks.nix-unit = pkgs.runCommand "nix-unit-tests" {} ''
|
||||
export NIX_PATH=nixpkgs=${pkgs.path}
|
||||
|
@ -105,6 +105,9 @@ in {
|
||||
in {
|
||||
# map all modules in /examples to a package output in the flake.
|
||||
checks =
|
||||
lib.optionalAttrs
|
||||
(system == "x86_64-linux")
|
||||
(
|
||||
(lib.mapAttrs (_: drvModules: makeDrv drvModules) allModules)
|
||||
// {
|
||||
example-repo =
|
||||
@ -115,6 +118,7 @@ in {
|
||||
.hello;
|
||||
example-repo-flake =
|
||||
(importFlake (self + /examples/dream2nix-repo-flake/flake.nix)).packages.${system}.hello;
|
||||
};
|
||||
}
|
||||
);
|
||||
};
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user