Something went wrong. Try again.
cleanroom implementation of a chess engine. doesn't work :)
Something went wrong. Try again.
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960{ inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.05"; flake-utils.url = "github:numtide/flake-utils"; fenix = { url = "github:nix-community/fenix"; inputs.nixpkgs.follows = "nixpkgs"; }; naersk = { url = "github:nix-community/naersk"; inputs.nixpkgs.follows = "nixpkgs"; }; };
outputs = { self, flake-utils, fenix, naersk, nixpkgs }: flake-utils.lib.eachDefaultSystem (system: let pkgs = (import nixpkgs) { inherit system; };
toolchain = fenix.packages.${system}.stable.toolchain;
naersk' = naersk.lib.${system}.override { rustc = toolchain; cargo = toolchain; };
in { # For `nix build` & `nix run`: packages.default = naersk'.buildPackage { src = ./.; };
formatter = toolchain;
checks = { build = self.packages.${system}.default; #fmt = pkgs.runCommand "fmt-check" { buildInputs = [ toolchain ]; } '' # cargo fmt --check # touch $out #''; #clippy = pkgs.runCommand "clippy-check" { buildInputs = [ toolchain ]; } '' # cargo clippy # touch $out #''; #tests = pkgs.runCommand "tests" { buildInputs = [ toolchain ]; } '' # cargo test # touch $out #''; };
# For `nix develop` (optional, can be skipped): devShells.default = pkgs.mkShell { buildInputs = [ toolchain ]; }; } );}