diff options
author | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2024-12-29 23:57:32 +0100 |
---|---|---|
committer | Benedikt Peetz <benedikt.peetz@b-peetz.de> | 2024-12-29 23:57:32 +0100 |
commit | e0ca2d19231c50543a6dc6bcc6335a3f9a84c595 (patch) | |
tree | af4a581ebb6aacb456ea493a16a9934e01b5dcef /rust/format/package.nix | |
parent | fix(src): Add some default stuff (diff) | |
download | qmk_layout-e0ca2d19231c50543a6dc6bcc6335a3f9a84c595.zip |
feat(src): Make usable
Diffstat (limited to 'rust/format/package.nix')
-rw-r--r-- | rust/format/package.nix | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/rust/format/package.nix b/rust/format/package.nix new file mode 100644 index 0000000..0595b61 --- /dev/null +++ b/rust/format/package.nix @@ -0,0 +1,27 @@ +{ + rustPlatform, + lib, +}: +rustPlatform.buildRustPackage { + pname = "format"; + version = "1.0.0"; + + src = lib.cleanSourceWith { + src = lib.cleanSource ./.; + filter = name: type: + (type == "directory") + || (builtins.elem (builtins.baseNameOf name) [ + "Cargo.toml" + "Cargo.lock" + "prints.txt" + "output_def.fs" + ]) + || (lib.strings.hasSuffix ".rs" (builtins.baseNameOf name)); + }; + + doCheck = true; + + cargoLock = { + lockFile = ./Cargo.lock; + }; +} |