fork/nix-minecraft

git clone https://git.julia.blue/fork/nix-minecraft

sweenutools/fetchModrinthModpack: init (#197)676dec3

lazymc
545 B25 linesraw
1{
2  fetchModrinthModpack,
3  stdenvNoCC,
4}:
5let
6  pack = fetchModrinthModpack {
7    src = ./sample-pack;
8    packHash = "sha256-OAJrZEVTZx1QZe2ubrLfK/XvRusfIN8cWMbj21TYhms=";
9  };
10in
11stdenvNoCC.mkDerivation {
12  name = "modrinth-modpack-from-src-check";
13  doCheck = true;
14  phases = [
15    "checkPhase"
16    "installPhase"
17  ];
18  checkPhase = ''
19    set -euo pipefail
20    test -f '${pack}/index.json'
21    test -f '${pack}/mods/lithium-fabric-0.16.2+mc1.21.5.jar'
22    test -f '${pack}/config/server.properties'
23  '';
24  installPhase = "mkdir $out";
25}