Skip to content
This repository has been archived by the owner on Jun 19, 2021. It is now read-only.

Commit

Permalink
yatoclip on jenkins
Browse files Browse the repository at this point in the history
  • Loading branch information
ishland committed May 16, 2021
1 parent fa1bc38 commit db5d951
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ pipeline {
sh 'rm -rf ./Paper/Paper-API ./Paper/Paper-Server'

// sh 'mv ./Paper/work/Minecraft ./ || true'
sh 'rm -fr ./Paper/work/*'
// sh 'rm -fr ./Paper/work/*'
// sh 'mv ./Minecraft ./Paper/work/ || true'


Expand Down Expand Up @@ -70,21 +70,13 @@ pipeline {
) {
withCredentials([usernamePassword(credentialsId: 'jenkins-deploy', usernameVariable: 'ORG_GRADLE_PROJECT_mavenUsername', passwordVariable: 'ORG_GRADLE_PROJECT_mavenPassword')]) {
sh '''
./gradlew build publish
./gradlew build publish yatoclip
mkdir -p "./target"
basedir=$(pwd)
paperworkdir="$basedir/Paper/work"
mcver=$(cat "$paperworkdir/BuildData/info.json" | grep minecraftVersion | cut -d '"' -f 4)
patchedJarPath=$(find "$basedir/Yatopia-Server/build/libs/" -type f -name "*.jar" | grep -v '\\-sources.jar$')
vanillaJarPath="$paperworkdir/Minecraft/$mcver/$mcver.jar"
cd "$paperworkdir/Paperclip"
mvn -T 2C clean package -Dmcver="$mcver" -Dpaperjar="$patchedJarPath" -Dvanillajar="$vanillaJarPath" -Dstyle.color=never
cd "$basedir"
cp -v "$paperworkdir/Paperclip/assembly/target/paperclip-$mcver.jar" "./target/yatopia-$mcver-paperclip-b$BUILD_NUMBER.jar"
cp -v "./yatopia-$mcver-yatoclip.jar" "./target/yatopia-$mcver-yatoclip-b$BUILD_NUMBER.jar"
'''
}
}
Expand Down

0 comments on commit db5d951

Please sign in to comment.