add nix flake

This commit is contained in:
xenofem 2022-08-27 15:16:00 -04:00
parent f9e967b7d6
commit 1448309be4
3 changed files with 47 additions and 1 deletions

3
.gitignore vendored
View file

@ -1 +1,2 @@
parent
parent
result

27
flake.lock Normal file
View file

@ -0,0 +1,27 @@
{
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1661450036,
"narHash": "sha256-0/9UyJLtfWqF4uvOrjFIzk8ue1YYUHa6JIhV0mALkH0=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "f3d0897be466aa09a37f6bf59e62c360c3f9a6cc",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

18
flake.nix Normal file
View file

@ -0,0 +1,18 @@
{
description = "Minimal process wrapper";
inputs.nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
outputs = { self, nixpkgs }: let
pkgs = import nixpkgs { system = "x86_64-linux"; };
in {
packages.x86_64-linux.parent = pkgs.buildGoModule {
pname = "parent";
version = "1.0";
src = ./.;
vendorSha256 = null;
};
defaultPackage.x86_64-linux = self.packages.x86_64-linux.parent;
};
}