tyrolienne/flake.nix
uku 09b4829281
fix(nix): don't add git rev to package version
causes a full deps rebuild each commit 🫠
2025-05-12 16:42:37 +02:00

41 lines
989 B
Nix

{
inputs = {
nixpkgs.url = "github:NixOS/nixpkgs?ref=nixos-unstable";
crane.url = "github:ipetkov/crane";
flake-parts = {
url = "github:hercules-ci/flake-parts";
inputs.nixpkgs-lib.follows = "nixpkgs";
};
};
outputs =
{ crane, flake-parts, ... }@inputs:
flake-parts.lib.mkFlake { inherit inputs; } {
systems = [
"x86_64-linux"
"aarch64-linux"
"x86_64-darwin"
"aarch64-darwin"
];
perSystem =
{ self', pkgs, ... }:
{
packages = {
tyrolienne = pkgs.callPackage ./package.nix { craneLib = crane.mkLib pkgs; };
default = self'.packages.tyrolienne;
};
devShells.default = pkgs.mkShell {
inputsFrom = [ self'.packages.default ];
packages = with pkgs; [
clippy
rust-analyzer
(rustfmt.override { asNightly = true; })
];
};
};
};
}