This commit is contained in:
Robin Appelman 2024-02-12 19:35:39 +01:00
commit cb685ded3e
4 changed files with 86 additions and 0 deletions

1
.envrc Normal file
View file

@ -0,0 +1 @@
use flake

2
.gitignore vendored
View file

@ -1,3 +1,5 @@
/target
**/*.rs.bk
Cargo.lock
.direnv
result

60
flake.lock generated Normal file
View file

@ -0,0 +1,60 @@
{
"nodes": {
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1705309234,
"narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1707761978,
"narHash": "sha256-izmjrbAfwwCu73I6GiVn4g7K3W7HyigKyYISj/Vw3Fs=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "1d103922e7783b5b3f8811d2325d297032c8f0d5",
"type": "github"
},
"original": {
"id": "nixpkgs",
"ref": "release-23.11",
"type": "indirect"
}
},
"root": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

23
flake.nix Normal file
View file

@ -0,0 +1,23 @@
{
inputs = {
nixpkgs.url = "nixpkgs/release-23.11";
flake-utils.url = "github:numtide/flake-utils";
};
outputs = {
self,
nixpkgs,
flake-utils,
...
}: let
inherit (flake-utils.lib) eachDefaultSystem eachSystem;
in eachDefaultSystem (system: let
pkgs = (import nixpkgs) {
inherit system;
};
in rec {
devShells.default = pkgs.mkShell {
nativeBuildInputs = with pkgs; [cargo rustc clippy bacon cargo-edit cargo-msrv];
};
});
}