mirror of
https://github.com/zaphar/kitchen.git
synced 2025-07-22 19:40:14 -04:00
First pass at a working nix flake
This commit is contained in:
parent
b46e5746b9
commit
131acf12da
25
flake.nix
Normal file
25
flake.nix
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
{
|
||||||
|
description = "kitchen";
|
||||||
|
inputs.nixpkgs = {
|
||||||
|
type = "indirect";
|
||||||
|
id = "nixpkgs";
|
||||||
|
};
|
||||||
|
inputs.gitignore = = { url = "github:hercules-ci/gitignore.nix"; flake = false; };
|
||||||
|
|
||||||
|
inputs.flake-utils.url = "github:numtide/flake-utils";
|
||||||
|
|
||||||
|
outputs = {self, nixpkgs, flake-utils}:
|
||||||
|
let
|
||||||
|
kitchenGen = import ./kitchen.nix;
|
||||||
|
gitignoreSrc = pkgs.callPackage inputs.gitignore { };
|
||||||
|
in
|
||||||
|
flake-utils.lib.eachDefaultSystem (system:
|
||||||
|
let pkgs = import nixpkgs { inherit system; }; in
|
||||||
|
{
|
||||||
|
defaultPackage = (kitchenGen {
|
||||||
|
nixpkgs = pkgs;
|
||||||
|
inherit gitignoreSrc;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
8
kitchen.nix
Normal file
8
kitchen.nix
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
{nixpkgs, gitignoreSrc}:
|
||||||
|
with nixpkgs;
|
||||||
|
rustPlatform.buildRustPackage {
|
||||||
|
pname = "kitchen";
|
||||||
|
version = "0.0.2";
|
||||||
|
src = gitignoreSrc.gitignoreSource ./.;
|
||||||
|
cargoSha256 = "sha256-DmUWZbZL8A5ht9ujx70qDvT6UC1CKiY6LtwWmKMvVhs=";
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user