add nix flake
Signed-off-by: Nicolas Froger <nicolas@kektus.xyz>
This commit is contained in:
parent
7e57bd218f
commit
dd808711ce
|
@ -0,0 +1,7 @@
|
|||
use_configsh() {
|
||||
watch_file config.sh
|
||||
eval "$(cat config.sh)"
|
||||
}
|
||||
|
||||
use_flake
|
||||
use_configsh
|
|
@ -0,0 +1,43 @@
|
|||
{
|
||||
"nodes": {
|
||||
"futils": {
|
||||
"locked": {
|
||||
"lastModified": 1656928814,
|
||||
"narHash": "sha256-RIFfgBuKz6Hp89yRr7+NR5tzIAbn52h8vT6vXkYjZoM=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "7e2a3b3dfd9af950a856d66b0a7d01e3c18aa249",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1659526864,
|
||||
"narHash": "sha256-XFzXrc1+6DZb9hBgHfEzfwylPUSqVFJbQPs8eOgYufU=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "478f3cbc8448b5852539d785fbfe9a53304133be",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-22.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"futils": "futils",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
{
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-22.05";
|
||||
futils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, futils } @ inputs:
|
||||
let
|
||||
inherit (nixpkgs) lib;
|
||||
inherit (lib) recursiveUpdate;
|
||||
inherit (futils.lib) eachDefaultSystem;
|
||||
|
||||
nixpkgsImport = system:
|
||||
import nixpkgs {
|
||||
inherit system;
|
||||
};
|
||||
|
||||
defaultSystemOutputs = eachDefaultSystem (system:
|
||||
let
|
||||
pkgs = nixpkgsImport system;
|
||||
in
|
||||
{
|
||||
devShells.default = pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
git
|
||||
go
|
||||
];
|
||||
};
|
||||
});
|
||||
in
|
||||
defaultSystemOutputs;
|
||||
}
|
Loading…
Reference in New Issue