diff options
author | Joel <joel@joel.tokyo> | 2021-12-11 20:42:56 +1000 |
---|---|---|
committer | Joel <joel@joel.tokyo> | 2022-01-24 20:59:45 +1000 |
commit | e54ce2616e8662d414f4dd24893df2af2b013800 (patch) | |
tree | 6d1a784b26d915de4143dc03bc80480e6d959c46 /pkgs/games | |
parent | be3f2d7f5d970c79bf7173ab6cb7cc851dce6a14 (diff) |
purpur: init at 1.17.1r1428
Update pkgs/games/purpur/default.nix Co-authored-by: Ivv <41924494+IvarWithoutBones@users.noreply.github.com> Update pkgs/games/purpur/default.nix Co-authored-by: Ivv <41924494+IvarWithoutBones@users.noreply.github.com> Update pkgs/games/purpur/default.nix Co-authored-by: Ivv <41924494+IvarWithoutBones@users.noreply.github.com> Update pkgs/games/purpur/default.nix Co-authored-by: Ivv <41924494+IvarWithoutBones@users.noreply.github.com> fix trailing white space purpur: 1.17.1r1428 -> 1.18.1r1522 add make wrapper
Diffstat (limited to 'pkgs/games')
-rw-r--r-- | pkgs/games/purpur/default.nix | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/pkgs/games/purpur/default.nix b/pkgs/games/purpur/default.nix new file mode 100644 index 0000000000000..b12c54449a488 --- /dev/null +++ b/pkgs/games/purpur/default.nix @@ -0,0 +1,41 @@ +{ lib, stdenv, fetchurl, nixosTests, jre_headless, makeWrapper }: + +stdenv.mkDerivation rec { + pname = "purpur"; + version = "1.18.1r1522"; + + src = fetchurl { + url = "https://api.purpurmc.org/v2/purpur/${builtins.replaceStrings [ "r" ] [ "/" ] version}/download"; + sha256 = "1060fsfcw6m30d47wla1vsnmc4czyla6m8wf91ws095hbvc22qsm"; + }; + + nativeBuildInputs = [ makeWrapper ]; + + preferLocalBuild = true; + + installPhase = '' + mkdir -p $out/bin $out/lib/minecraft + cp -v $src $out/lib/minecraft/server.jar + + makeWrapper ${jre_headless}/bin/java $out/bin/minecraft-server \ + --add-flags "-jar $out/lib/minecraft/server.jar nogui" + ''; + + dontUnpack = true; + + passthru = { + tests = { inherit (nixosTests) minecraft-server; }; + }; + + meta = with lib; { + description = "A drop-in replacement for Minecraft Paper servers"; + longDescription = '' + Purpur is a drop-in replacement for Minecraft Paper servers designed for configurability, new fun and exciting + gameplay features, and performance built on top of Airplane. + ''; + homepage = "https://purpurmc.org/"; + license = licenses.mit; + platforms = platforms.unix; + maintainers = with maintainers; [ jyooru ]; + }; +} |