-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdefault.nix
44 lines (44 loc) · 974 Bytes
/
default.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
{
system ? builtins.currentSystem,
inputs ? import ./flake.lock.nix {},
nixpkgs ?
import inputs.nixpkgs {
inherit system;
# Makes the config pure as well. See <nixpkgs>/top-level/impure.nix:
config = {};
overlays = [];
},
buildGoModule ? nixpkgs.buildGoModule,
}: let
serve-go =
buildGoModule
{
name = "serve-go";
src = ./.;
vendorSha256 = null;
meta = with nixpkgs.lib; {
description = "HTTP web server for SPA";
homepage = "https://github.com/numtide/serve-go";
license = licenses.mit;
maintainers = with maintainers; [zimbatm jfroche];
platforms = platforms.linux;
};
};
devShell =
nixpkgs.mkShellNoCC
{
buildInputs = with nixpkgs; [
gofumpt
golangci-lint
alejandra
go
golint
treefmt
just
gcc
];
};
in {
inherit serve-go devShell;
default = serve-go;
}