Test new Jenkins File
Some checks failed
andreas-personal/AndysAdguardHomeBlockList/pipeline/head There was a failure building this commit

This commit is contained in:
Andreas Fahrecker 2024-04-10 01:34:07 +02:00
parent a3655a8ee4
commit 64d96165fe

57
Jenkinsfile vendored
View File

@ -1,40 +1,35 @@
#!groovy
pipeline {
agent none
agent {
label 'linux'
}
when {
beforeAgent true;
branch 'main'
}
stages {
stage('Compile List and Push to Gitea') {
when {
beforeAgent true;
branch 'main'
stage('NPM Install') {
steps {
sh 'npm clean-install'
}
agent {
label 'linux'
}
stage('Compile Adblock List') {
steps {
sh 'npm run compile'
}
stages {
stage('NPM Install') {
steps {
sh 'npm clean-install'
}
}
stage('Compile Adblock List') {
steps {
sh 'npm run compile'
}
}
stage('git push') {
steps {
withCredentials([
gitUsernamePassword(credentialsId: 'gitea-jenkins-user-token')
]) {
sh '''
git add .
git commit -m "Update Compiled Adblock List"
git push
'''
}
}
}
stage('git push') {
steps {
withCredentials([
gitUsernamePassword(credentialsId: 'gitea-jenkins-user-token')
]) {
sh '''
git checkout main
git add .
git commit -m "Update Compiled Adblock List"
git push
'''
}
}
}