2022-07-07 15:15:05 +01:00
|
|
|
clone:
|
|
|
|
git:
|
|
|
|
image: woodpeckerci/plugin-git:latest
|
2022-07-07 14:34:42 +01:00
|
|
|
settings:
|
2022-07-07 15:15:05 +01:00
|
|
|
path: MagicStorageVoidBag
|
2022-07-07 22:41:05 +01:00
|
|
|
when:
|
|
|
|
event: tag
|
2022-07-07 14:34:42 +01:00
|
|
|
|
2022-07-07 15:15:05 +01:00
|
|
|
pipeline:
|
2022-07-07 17:17:43 +01:00
|
|
|
fetch-deps:
|
2022-12-03 14:59:08 +00:00
|
|
|
image: jackbondpreston/msvb-build-env
|
2022-07-07 17:17:43 +01:00
|
|
|
commands:
|
2022-12-03 14:59:08 +00:00
|
|
|
- steamcmd "+login anonymous" "+workshop_download_item 1281930 2563309347" "+quit"
|
2022-07-07 17:17:43 +01:00
|
|
|
- wget https://github.com/tModLoader/tModLoader/releases/latest/download/tModLoader.zip
|
2022-07-07 17:55:45 +01:00
|
|
|
- unzip -q tModLoader.zip -d tModLoader
|
2022-07-07 17:17:43 +01:00
|
|
|
- rm tModLoader.zip
|
2022-07-07 17:55:45 +01:00
|
|
|
- ln -sf $CI_WORKSPACE/tModLoader/Libraries/Native/Linux/libSDL2-2.0.so.0 $CI_WORKSPACE/tModLoader/Libraries/Native/Linux/libSDL2.so
|
|
|
|
- >
|
|
|
|
echo "<Project ToolsVersion=\"14.0\" xmlns=\"http://schemas.microsoft.com/developer/msbuild/2003\">
|
|
|
|
<Import Project=\"$CI_WORKSPACE/tModLoader/tMLMod.targets\" />
|
|
|
|
</Project>" > tModLoader.targets
|
2022-12-03 14:59:08 +00:00
|
|
|
- |
|
|
|
|
wget https://github.com/steviegt6/tml-patcher/releases/latest/download/TML.Patcher.zip
|
|
|
|
unzip -q TML.Patcher.zip -d TMLPatcher
|
|
|
|
- |
|
|
|
|
rm -f /root/.steam/steamapps/workshop/content/1281930/2563309347/workshop.json
|
2023-02-04 13:13:29 +00:00
|
|
|
YEAR=$(ls /root/.steam/steamapps/workshop/content/1281930/2563309347 | cut -c -4 | sort -nr | head -n 1)
|
|
|
|
VER=$(find /root/.steam/steamapps/workshop/content/1281930/2563309347/ -type d -name "$YEAR.*" -printf "%f\n" | cut -c 6- | sort -nr | head -n 1)
|
2022-12-03 14:59:08 +00:00
|
|
|
cp /root/.steam/steamapps/workshop/content/1281930/2563309347/$YEAR.$VER/MagicStorage.tmod ./
|
|
|
|
- dotnet TMLPatcher/TML.Patcher.dll extract MagicStorage.tmod
|
|
|
|
- cp MagicStorage/MagicStorage.dll $CI_WORKSPACE/
|
2022-07-07 22:41:05 +01:00
|
|
|
when:
|
|
|
|
event: tag
|
2022-07-07 17:55:45 +01:00
|
|
|
|
2022-07-07 13:44:56 +01:00
|
|
|
build:
|
2022-12-03 14:59:08 +00:00
|
|
|
image: jackbondpreston/msvb-build-env
|
2022-07-07 13:44:56 +01:00
|
|
|
commands:
|
2022-07-07 17:55:45 +01:00
|
|
|
- |
|
|
|
|
echo "Shell: $SHELL"
|
|
|
|
echo "CI_WORKSPACE: $CI_WORKSPACE"
|
|
|
|
- cat tModLoader.targets
|
|
|
|
- cd $CI_WORKSPACE
|
2022-07-07 22:55:07 +01:00
|
|
|
- cd MagicStorageVoidBag
|
|
|
|
- rm -rf .git
|
|
|
|
- dotnet build -c Release || true
|
2022-07-07 17:55:45 +01:00
|
|
|
- cp bin/Release/net6.0/MagicStorageVoidBag.dll .
|
|
|
|
- cd $CI_WORKSPACE
|
2022-07-07 22:35:31 +01:00
|
|
|
- mkdir release
|
|
|
|
- cp ~/.local/share/Terraria/tModLoader/Mods/MagicStorageVoidBag.tmod release/
|
|
|
|
- cp MagicStorageVoidBag/MagicStorageVoidBag.dll release/
|
|
|
|
- ls release
|
2022-07-07 22:41:05 +01:00
|
|
|
when:
|
|
|
|
event: tag
|
2022-07-07 22:35:31 +01:00
|
|
|
|
|
|
|
gitea-release:
|
|
|
|
image: plugins/gitea-release
|
|
|
|
settings:
|
|
|
|
api_key:
|
|
|
|
from_secret: gitea-api-key
|
|
|
|
base_url: https://git.jackbondpreston.me
|
|
|
|
files: release/*
|
|
|
|
when:
|
|
|
|
event: tag
|
2022-07-07 23:07:44 +01:00
|
|
|
|