mirror of
https://github.com/EarthMC/QuickShop-Reremake.git
synced 2026-11-24 09:39:40 -05:00
Former-commit-id: 71c815712652dfc4ce691eb904214412263b044e [formerly fe67049c1089bbbf902134cece1bccc6a72e3ae3] Former-commit-id: e1e2829bc997fcd84a26aed9a9c98339a6bf2961
22 lines
753 B
Bash
22 lines
753 B
Bash
#!/bin/sh
|
|
echo "Deploy jar to dev.bukkit.org"
|
|
|
|
# 获取从install完成后输出的JAR文件的名字
|
|
filename="./jarname.txt"
|
|
|
|
if [ ! -f $filename ]
|
|
then
|
|
echo "The file $filename doesn't exist."
|
|
exit 1
|
|
fi
|
|
|
|
# JAR为编译后jar文件名称
|
|
read JAR < $filename
|
|
xToken=$1
|
|
curl -X POST -H "X-Api-Token: $xToken" -F 'metadata={"changelog":"Auto upload by TravisCI, see update details on <a href="https://www.spigotmc.org/resources/quickshop-reremake-now-support-1-14.62575/">spigotmc.org</a>","gameVersions":[7330,7105],"releaseType":"release"}' -F "file=@./push/$JAR" -s "https://dev.bukkit.org/api/projects/320536/upload-file" > fileid.json
|
|
cat fileid.json
|
|
echo "Finished upload to dev.bukkit.org."
|
|
|
|
#退出脚本,且退出状态码为0
|
|
exit 0
|