initial commit

This commit is contained in:
bit 2025-08-07 09:02:49 +02:00
commit d4fffab962
2 changed files with 68 additions and 0 deletions

27
flake.lock generated Normal file
View File

@ -0,0 +1,27 @@
{
"nodes": {
"nixpkgs": {
"locked": {
"lastModified": 1754214453,
"narHash": "sha256-Q/I2xJn/j1wpkGhWkQnm20nShYnG7TI99foDBpXm1SY=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "5b09dc45f24cf32316283e62aec81ffee3c3e376",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}

41
flake.nix Normal file
View File

@ -0,0 +1,41 @@
{
inputs = {
nixpkgs.url = "github:nixos/nixpkgs?ref=nixos-unstable";
};
outputs =
{ self, nixpkgs }:
let
defaultSystems = [
"aarch64-linux"
"aarch64-darwin"
"x86_64-darwin"
"x86_64-linux"
];
forAllDefaultSystems = f: nixpkgs.lib.genAttrs defaultSystems (system: f system);
in
{
devShells = forAllDefaultSystems (
system:
let
pkgs = import nixpkgs { inherit system; };
in
{
#default = self.devShells."${system}".;
rust = pkgs.mkShell {
buildInputs = with pkgs; [
rustc
cargo
gcc
rustfmt
clippy
];
};
}
);
formatter = forAllDefaultSystems (system: nixpkgs.legacyPackages.${system}.nixfmt-tree);
};
}