mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-06-29 01:54:20 +03:00
refactor(nix): nix-filter -> lib.fileset
with our own use of `map`, this is basically a drop-in replacement for nix-filter, but already in nixpkgs! Signed-off-by: seth <getchoo@tuta.io>
This commit is contained in:
parent
7bce88e83e
commit
8312713dc2
4 changed files with 13 additions and 35 deletions
|
|
@ -26,24 +26,8 @@
|
|||
overlays.default = final: prev: let
|
||||
version = builtins.substring 0 8 self.lastModifiedDate or "dirty";
|
||||
|
||||
filteredSelf = inputs.nix-filter.lib.filter {
|
||||
root = ../.;
|
||||
include = [
|
||||
"buildconfig"
|
||||
"cmake"
|
||||
"launcher"
|
||||
"libraries"
|
||||
"program_info"
|
||||
"tests"
|
||||
../COPYING.md
|
||||
../CMakeLists.txt
|
||||
];
|
||||
};
|
||||
|
||||
# common args for prismlauncher evaluations
|
||||
unwrappedArgs = {
|
||||
self = filteredSelf;
|
||||
|
||||
inherit (inputs) libnbtplusplus;
|
||||
inherit ((final.darwin or prev.darwin).apple_sdk.frameworks) Cocoa;
|
||||
inherit version;
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
gamemode,
|
||||
msaClientID ? null,
|
||||
gamemodeSupport ? stdenv.isLinux,
|
||||
self,
|
||||
version,
|
||||
libnbtplusplus,
|
||||
}:
|
||||
|
|
@ -25,7 +24,19 @@ assert lib.assertMsg (stdenv.isLinux || !gamemodeSupport) "gamemodeSupport is on
|
|||
pname = "prismlauncher-unwrapped";
|
||||
inherit version;
|
||||
|
||||
src = lib.cleanSource self;
|
||||
src = lib.fileset.toSource {
|
||||
root = ../../.;
|
||||
fileset = lib.fileset.unions (map (fileName: ../../${fileName}) [
|
||||
"buildconfig"
|
||||
"cmake"
|
||||
"launcher"
|
||||
"libraries"
|
||||
"program_info"
|
||||
"tests"
|
||||
"COPYING.md"
|
||||
"CMakeLists.txt"
|
||||
]);
|
||||
};
|
||||
|
||||
nativeBuildInputs = [extra-cmake-modules cmake jdk17 ninja canonicalize-jars-hook];
|
||||
buildInputs =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue