mirror of
https://github.com/WiVRn/WiVRn.git
synced 2026-11-30 13:53:02 -08:00
Filter src in flake
This commit is contained in:
1 parent
db66b0dbb7
commit
0ec2cd5a3e
1 file changed
+15
-1
@@ -26,7 +26,21 @@
|
||||
];
|
||||
|
||||
package = pkgs.enableDebugging (pkgs.wivrn.overrideAttrs (finalAttrs: oldAttrs: {
|
||||
src = ./.;
|
||||
# Filter the directories and files we don't need to keep to avoid needless rebuilds
|
||||
src = lib.cleanSourceWith {
|
||||
filter = name: type: let
|
||||
baseName = baseNameOf (toString name);
|
||||
in
|
||||
(lib.cleanSourceFilter name type) &&
|
||||
!(
|
||||
(type == "directory" && (
|
||||
baseName == ".direnv"
|
||||
|| baseName == ".cxx"
|
||||
|| lib.hasPrefix "build" baseName))
|
||||
|| baseName == ".envrc"
|
||||
);
|
||||
src = ./.;
|
||||
};
|
||||
version = "next";
|
||||
|
||||
# Because src is just a folder path and not a set from a fetcher, it doesn't need to be unpacked, so having a postUnpack throws an error.
|
||||
|
||||
Reference in new issue
Block a user