From 0958674598cf0c6889c14b79c998bf8a40767249 Mon Sep 17 00:00:00 2001 From: Merith TK Date: Tue, 1 Mar 2022 18:47:39 -0800 Subject: [PATCH] restructure template for ease of use --- .gitignore | 2 +- {packwiz-data => .minecraft}/index.toml | 12 +++++++++++ .../mods/lithium.toml | 0 .../mods/phosphor.toml | 0 {packwiz-data => .minecraft}/mods/sodium.toml | 0 {packwiz-data => .minecraft}/pack.toml | 2 +- Makefile | 20 ++++++++++--------- instance.cfg | 2 +- 8 files changed, 26 insertions(+), 12 deletions(-) rename {packwiz-data => .minecraft}/index.toml (53%) rename {packwiz-data => .minecraft}/mods/lithium.toml (100%) rename {packwiz-data => .minecraft}/mods/phosphor.toml (100%) rename {packwiz-data => .minecraft}/mods/sodium.toml (100%) rename {packwiz-data => .minecraft}/pack.toml (72%) diff --git a/.gitignore b/.gitignore index a533173..c8d7bd8 100644 --- a/.gitignore +++ b/.gitignore @@ -11,8 +11,8 @@ ## Ignore Modpack Updater Script loose files .technic *.zip +*.mrpack ## Add your modded folders/files to ignore here -.minecraft/mods/ .minecraft/packwiz-installer.jar .minecraft/packwiz.json diff --git a/packwiz-data/index.toml b/.minecraft/index.toml similarity index 53% rename from packwiz-data/index.toml rename to .minecraft/index.toml index aeb5cf3..1040aea 100644 --- a/packwiz-data/index.toml +++ b/.minecraft/index.toml @@ -1,5 +1,13 @@ hash-format = "sha256" +[[files]] +file = "bin/version.json" +hash = "b5f8dc11af2e5d2eeb17007a53fced417fdb3020baac8a8f8dd230a2d3fd854e" + +[[files]] +file = "modpack.icon.png" +hash = "50f74a7debb4a852e1384434500515f2478b8dcf0d71b75eba148ca34d89715c" + [[files]] file = "mods/lithium.toml" hash = "5a5c6174eda3db8594761efaf64308c44702b3f2a25957b0c35825b0109a1ef0" @@ -14,3 +22,7 @@ metafile = true file = "mods/sodium.toml" hash = "4aba93a705eb2c6300818297bc1d85329b9b085392810dbf15c79b5e3dd6d0ef" metafile = true + +[[files]] +file = "packwiz-installer-bootstrap.jar" +hash = "a8fbb24dc604278e97f4688e82d3d91a318b98efc08d5dbfcbcbcab6443d116c" diff --git a/packwiz-data/mods/lithium.toml b/.minecraft/mods/lithium.toml similarity index 100% rename from packwiz-data/mods/lithium.toml rename to .minecraft/mods/lithium.toml diff --git a/packwiz-data/mods/phosphor.toml b/.minecraft/mods/phosphor.toml similarity index 100% rename from packwiz-data/mods/phosphor.toml rename to .minecraft/mods/phosphor.toml diff --git a/packwiz-data/mods/sodium.toml b/.minecraft/mods/sodium.toml similarity index 100% rename from packwiz-data/mods/sodium.toml rename to .minecraft/mods/sodium.toml diff --git a/packwiz-data/pack.toml b/.minecraft/pack.toml similarity index 72% rename from packwiz-data/pack.toml rename to .minecraft/pack.toml index 0e90731..ed17aed 100644 --- a/packwiz-data/pack.toml +++ b/.minecraft/pack.toml @@ -6,7 +6,7 @@ pack-format = "packwiz:1.0.0" [index] file = "index.toml" hash-format = "sha256" -hash = "966ec7345bb3c3de690051089956c93804081fbcb5b6e2484304f14c266bd397" +hash = "d021bf567c5145418d5c6aec8806f0c9b0d7f8cf9b8a820301e8998e797f59c0" [versions] fabric = "0.13.3" diff --git a/Makefile b/Makefile index d745660..f18272f 100644 --- a/Makefile +++ b/Makefile @@ -17,26 +17,28 @@ default: curseforge: @echo "Making Curseforge pack" - @-mkdir ../modpack-curseforge - packwiz curseforge export --mods-folder packwiz-data/mods/ --pack-file packwiz-data/pack.toml - cp -r .minecraft overrides - 7z a *.zip overrides - rm -rf overrides - mv *.zip ../modpack-curseforge/ + packwiz curseforge export --pack-file .minecraft/pack.toml -o ../modpack-curseforge.zip + 7z d ../modpack-curseforge.zip overrides/packwiz-installer-bootstrap.jar overrides/pack.toml overrides/index.toml + +modrinth: + @echo "Making Modrinth pack" + packwiz modrinth export --pack-file .minecraft/pack.toml -o ../modpack-modrinth.zip + 7z d ../modpack-modrinth.zip overrides/packwiz-installer-bootstrap.jar overrides/pack.toml overrides/index.toml multimc: @echo "Making MultiMC pack" 7z d ../modpack-multimc.zip ./* -r - 7z d ../modpack-multimc.zip ./.* -r + 7z d ../modpack-multimc.zip ./.minecraft -r 7z a ../modpack-multimc.zip ./* -r 7z a ../modpack-multimc.zip ./.minecraft -r + 7z d ../modpack-multimc.zip ./.minecraft/mods ./.minecraft/pack.toml ./.minecraft/index.toml -r technic: @echo "Making Technic pack" -rm -rf .technic -cp -r .minecraft .technic mv .technic/modpack.icon.png .technic/icon.png - cd .technic && java -jar packwiz-installer-bootstrap.jar https://gitlab.com/Merith-TK/modpack-template/-/raw/main/packwiz-data/pack.toml && cd .. + cd .technic && java -jar packwiz-installer-bootstrap.jar https://gitlab.com/Merith-TK/modpack-template/-/raw/main/.minecraft/pack.toml && cd .. -rm -rf .technic/packwiz* 7z d ../modpack-technic.zip ./* -r 7z a ../modpack-technic.zip ./.technic/* -r @@ -45,4 +47,4 @@ clean: -rm -rf .technic -git gc --aggressive --prune -all: curseforge multimc technic clean +all: curseforge modrinth multimc technic clean diff --git a/instance.cfg b/instance.cfg index fb800b1..9a8fb42 100644 --- a/instance.cfg +++ b/instance.cfg @@ -2,4 +2,4 @@ InstanceType=OneSix iconKey=modpack.icon name=Modpack Template OverrideCommands=true -PreLaunchCommand=$INST_JAVA -jar packwiz-installer-bootstrap.jar https://gitlab.com/Merith-TK/modpack-template/-/raw/packwiz/packwiz-data/pack.toml \ No newline at end of file +PreLaunchCommand=$INST_JAVA -jar packwiz-installer-bootstrap.jar https://gitlab.com/Merith-TK/modpack-template/-/raw/main/.minecraft/pack.toml \ No newline at end of file