forked from akshettrj/watgbridge
-
Notifications
You must be signed in to change notification settings - Fork 0
/
flake.nix
48 lines (42 loc) · 1.26 KB
/
flake.nix
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
48
{
description = "Flake for watgbridge";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
flake-utils.url = "github:numtide/flake-utils";
nix-filter.url = "github:numtide/nix-filter";
gomod2nix = {
url = "github:nix-community/gomod2nix";
inputs.nixpkgs.follows = "nixpkgs";
};
};
outputs = { self, nixpkgs, flake-utils, gomod2nix, nix-filter }:
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs {
inherit system;
overlays = [ gomod2nix.overlays.default ];
};
in
with pkgs; {
devShells.default = mkShell {
name = "watgbridge-dev";
nativeBuildInputs = [
go
gopls
delve
libwebp
gomod2nix.packages."${system}".default
];
hardeningDisable = [ "fortify" ];
};
packages = rec {
watgbridge = (pkgs.callPackage ./nix/pkgs/watgbridge-dev.nix { inherit nix-filter; });
default = watgbridge;
};
}
);
nixConfig = {
extra-substituters = [ "https://watgbridge.cachix.org" ];
extra-trusted-public-keys = [ "watgbridge.cachix.org-1:KSfgmbSBvXQTpUnoCj21vST7zgwpy3SbNfk0/nesR1Y=" ];
};
}