summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--flake.nix89
1 files changed, 43 insertions, 46 deletions
diff --git a/flake.nix b/flake.nix
index 665c55b..a101868 100644
--- a/flake.nix
+++ b/flake.nix
@@ -13,54 +13,51 @@
};
outputs =
inputs@{ flake-parts, ... }:
- flake-parts.lib.mkFlake { inherit inputs; } (
- top@{ config, ... }:
- {
- imports = [ inputs.treefmt-nix.flakeModule ];
- systems = [
- "aarch64-darwin"
- "aarch64-linux"
- "x86_64-darwin"
- "x86_64-linux"
- ];
- perSystem =
- { pkgs, ... }:
- let
- naersk' = pkgs.callPackage inputs.naersk { };
- nativeBuildInputs' = with pkgs; [
- cargo
- cmake
- flac
- rustc
- sqlite
- ];
- in
- {
- packages.default = naersk'.buildPackage {
- src = ./.;
- nativeBuildInputs = nativeBuildInputs';
- };
+ flake-parts.lib.mkFlake { inherit inputs; } {
+ imports = [ inputs.treefmt-nix.flakeModule ];
+ systems = [
+ "aarch64-darwin"
+ "aarch64-linux"
+ "x86_64-darwin"
+ "x86_64-linux"
+ ];
+ perSystem =
+ { pkgs, ... }:
+ let
+ naersk' = pkgs.callPackage inputs.naersk { };
+ nativeBuildInputs' = with pkgs; [
+ cargo
+ cmake
+ flac
+ rustc
+ sqlite
+ ];
+ in
+ {
+ packages.default = naersk'.buildPackage {
+ src = ./.;
+ nativeBuildInputs = nativeBuildInputs';
+ };
- devShells.default = pkgs.mkShell {
- nativeBuildInputs = nativeBuildInputs';
- packages = with pkgs; [
- nixd
- nixfmt
- rust-analyzer
- rustfmt
- clippy
- ];
- };
+ devShells.default = pkgs.mkShell {
+ nativeBuildInputs = nativeBuildInputs';
+ packages = with pkgs; [
+ nixd
+ nixfmt
+ rust-analyzer
+ rustfmt
+ clippy
+ ];
+ };
- treefmt = {
- projectRootFile = "flake.nix";
- programs = {
- nixfmt.enable = true;
- rustfmt.enable = true;
- taplo.enable = true;
- };
+ treefmt = {
+ projectRootFile = "flake.nix";
+ programs = {
+ nixfmt.enable = true;
+ rustfmt.enable = true;
+ taplo.enable = true;
};
};
- }
- );
+ };
+ };
}