From adbb204ef53115da7a84fce6632afcfb73b2309b Mon Sep 17 00:00:00 2001 From: Harrison Deng Date: Tue, 17 May 2022 13:04:59 -0500 Subject: [PATCH] Added ps1 script for running server, removed dependency on .sh script. --- Jenkinsfile | 5 ++--- run.ps1 | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) create mode 100644 run.ps1 diff --git a/Jenkinsfile b/Jenkinsfile index 67cef6b..a48fbfa 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -15,9 +15,8 @@ pipeline { } steps { fileOperations([fileCreateOperation(fileContent: 'eula=true', fileName: 'eula.txt')]) - pwsh returnStatus: true, script: 'chmod u+x ./run_trial.sh' fileOperations([fileDownloadOperation(password: '', proxyHost: '', proxyPort: '', targetFileName: 'DynmapBlockScan.jar', targetLocation: 'mods/', url: 'https://github.com/webbukkit/DynmapBlockScan/releases/download/v3.4-beta-1/DynmapBlockScan-3.4-beta-1-forge-1.18.jar', userName: '')]) - pwsh 'echo "stop" | ./run_trial.sh' + pwsh returnStatus: true, script: 'echo "stop" | java -Xmx4G @libraries/net/minecraftforge/forge/1.18.2-40.1.19/unix_args.txt' logParser failBuildOnError: true, projectRulePath: 'Jenkinsparse', parsingRulesPath: 'Jenkinsparse', showGraphs: true, unstableOnWarning: true, useProjectRule: true fileOperations([fileDeleteOperation(excludes: '', includes: 'mods/DynmapBlockScan.jar')]) } @@ -30,7 +29,7 @@ pipeline { } steps { pwsh "git clean -dfX" - pwsh "rm -rf world" + fileOperations([folderDeleteOperation('world')]) } } stage("deploy") { diff --git a/run.ps1 b/run.ps1 new file mode 100644 index 0000000..f26e0ce --- /dev/null +++ b/run.ps1 @@ -0,0 +1 @@ +java "@user_jvm_args.txt" "@libraries/net/minecraftforge/forge/1.18.2-40.1.19/unix_args.txt" $args