papermario/Jenkinsfile

102 lines
4.2 KiB
Plaintext
Raw Normal View History

2020-08-15 06:12:23 +02:00
pipeline {
2021-01-18 14:05:32 +01:00
agent {
label 'papermario'
2021-01-18 14:05:32 +01:00
}
2020-08-15 06:12:23 +02:00
stages {
stage('Setup') {
steps {
sh 'cp /usr/local/etc/roms/papermario.us.z64 ver/us/baserom.z64'
sh 'cp /usr/local/etc/roms/papermario.jp.z64 ver/jp/baserom.z64'
sh 'curl -L "https://github.com/pmret/gcc-papermario/releases/download/master/linux.tar.gz" | tar zx -C tools/build/cc/gcc'
sh 'curl -L "https://github.com/pmret/binutils-papermario/releases/download/master/linux.tar.gz" | tar zx -C tools/build/cc/gcc'
sh 'curl -L "https://github.com/ethteck/ido-static-recomp/releases/download/per-function/ido-5.3-recomp-ubuntu-latest.tar.gz" | tar zx -C tools/build/cc/ido5.3'
sh 'curl -L "https://github.com/decompals/mips-gcc-2.7.2/releases/download/main/gcc-2.7.2-linux.tar.gz" | tar zx -C tools/build/cc/gcc2.7.2'
sh 'curl -L "https://github.com/decompals/mips-binutils-2.6/releases/download/main/binutils-2.6-linux.tar.gz" | tar zx -C tools/build/cc/gcc2.7.2'
Upgrade to splat 0.9.0 (#730) * changes for splat 0.9.0 * wip * git subrepo pull --branch=develop --force tools/splat subrepo: subdir: "tools/splat" merged: "2ff7357501" upstream: origin: "https://github.com/ethteck/splat.git" branch: "develop" commit: "2ff7357501" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * OK * big_snowflakes gfx data * Jenkins? * cleanup * debuff effect gfx data * fix * more effect gfx data * dlabel * git subrepo pull --branch=experiment --force tools/splat subrepo: subdir: "tools/splat" merged: "1365775e09" upstream: origin: "https://github.com/ethteck/splat.git" branch: "experiment" commit: "1365775e09" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * . * git subrepo pull --branch=experiment --force tools/splat subrepo: subdir: "tools/splat" merged: "6bd9fe1c4e" upstream: origin: "https://github.com/ethteck/splat.git" branch: "experiment" commit: "6bd9fe1c4e" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * flower splash/trail gfx * throw_spiny gfx * disable_x and butterflies gfx data * draw_coin_sparkles * Warnings, cleanup * cleanin * attempt at test_item_player_collision * more gfx + cleanup * more effect gfx * func_8002D160 * update update_symbol_addrs and symbol_addrs * git subrepo pull --branch=develop --force tools/splat subrepo: subdir: "tools/splat" merged: "4914dc9029" upstream: origin: "https://github.com/ethteck/splat.git" branch: "develop" commit: "4914dc9029" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * git subrepo pull --branch=master --force tools/splat subrepo: subdir: "tools/splat" merged: "aa71299594" upstream: origin: "https://github.com/ethteck/splat.git" branch: "master" commit: "aa71299594" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * fix * fix regression * Add rabbitizer to requirements * warnings * symbol_addrs fixes
2022-06-12 17:33:32 +02:00
sh 'pip install -r requirements.txt'
sh './configure'
2020-08-15 06:12:23 +02:00
}
}
stage('Build') {
steps {
2021-09-22 13:40:16 +02:00
sh "bash -o pipefail -c 'ninja 2>&1 | tee build_log.txt'"
2020-08-15 06:12:23 +02:00
}
}
stage("Comment") {
when {
not {
branch 'master'
}
}
steps {
script {
if (env.CHANGE_ID) {
def us_progress = sh(returnStdout: true, script: "python3 progress.py us --pr-comment").trim()
def jp_progress = sh(returnStdout: true, script: "python3 progress.py jp --pr-comment").trim()
def warnings = sh(returnStdout: true, script: "./tools/warnings_count/check_new_warnings.sh --jenkins").trim()
def comment_id = -1
for (comment in pullRequest.comments) {
if (comment.user == "BowserSlug") {
comment_id = comment.id
}
}
def message = "${us_progress}\n${jp_progress}\n${warnings}"
if (message != "\n\n") {
if (comment_id == -1) {
pullRequest.comment(message)
} else {
pullRequest.editComment(comment_id, message)
}
}
}
}
}
}
2021-01-04 14:50:33 +01:00
stage('Report Progress') {
when {
branch 'master'
}
steps {
sh 'mkdir reports'
sh 'python3 progress.py us --csv >> reports/progress_us.csv'
sh 'python3 progress.py us --shield-json > reports/progress_us_shield.json'
sh 'python3 progress.py jp --csv >> reports/progress_jp.csv'
sh 'python3 progress.py jp --shield-json > reports/progress_jp_shield.json'
sh 'cat build_log.txt | grep warning | sort > tools/warnings_count/warnings.txt'
sh 'cp tools/warnings_count/warnings.txt reports/warnings.txt'
stash includes: 'reports/*', name: 'reports'
}
}
stage('Update Progress') {
when {
branch 'master'
}
agent {
label 'master'
}
steps {
unstash 'reports'
sh 'cat reports/progress_us.csv >> /var/www/papermar.io/html/reports/progress_us.csv'
sh 'cat reports/progress_us_shield.json > /var/www/papermar.io/html/reports/progress_us_shield.json'
sh 'cat reports/progress_jp.csv >> /var/www/papermar.io/html/reports/progress_jp.csv'
sh 'cat reports/progress_jp_shield.json > /var/www/papermar.io/html/reports/progress_jp_shield.json'
sh 'cat reports/warnings.txt > /var/www/papermar.io/html/reports/warnings.txt'
2021-01-04 14:50:33 +01:00
}
}
2020-08-15 06:12:23 +02:00
}
post {
always {
cleanWs()
}
}
2020-08-15 06:12:23 +02:00
}