-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathflake.nix
More file actions
47 lines (43 loc) · 1.47 KB
/
flake.nix
File metadata and controls
47 lines (43 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
{
outputs =
inputs:
inputs.parts.lib.mkFlake { inherit inputs; } (
{ lib, ... }:
let
lift =
func: path:
func (
lib.modules.importApply path {
inherit inputs;
std = builtins // lib;
}
);
in
{
systems = import inputs.systems;
flake.nixosModules.default = lift lib.id ./module.nix;
perSystem =
{ pkgs, system, ... }:
{
_module.args.pkgs = import inputs.nixpkgs {
inherit system;
config.allowDeprecatedx86_64Darwin = true;
overlays = [ inputs.gomod2nix.overlays.default ];
};
checks.default = lift pkgs.testers.runNixOSTest ./test.nix;
devShells.default = pkgs.callPackage ./shell.nix { };
formatter = pkgs.callPackage ./formatter.nix { };
packages.default = pkgs.callPackage ./default.nix { };
};
}
);
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
inputs.systems.url = "github:nix-systems/default";
inputs.parts.url = "github:hercules-ci/flake-parts";
inputs.parts.inputs.nixpkgs-lib.follows = "nixpkgs";
inputs.utils.url = "github:numtide/flake-utils";
inputs.utils.inputs.systems.follows = "systems";
inputs.gomod2nix.url = "github:nix-community/gomod2nix";
inputs.gomod2nix.inputs.nixpkgs.follows = "nixpkgs";
inputs.gomod2nix.inputs.flake-utils.follows = "utils";
}