Test
Some checks failed
andreas-personal/AndysAdguardHomeBlockList/pipeline/head There was a failure building this commit
Some checks failed
andreas-personal/AndysAdguardHomeBlockList/pipeline/head There was a failure building this commit
This commit is contained in:
parent
36a97f7421
commit
4aea6047bb
27
Jenkinsfile
vendored
27
Jenkinsfile
vendored
@ -11,14 +11,15 @@ pipeline {
|
|||||||
branch 'main'
|
branch 'main'
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
dir ('build-dir') {
|
// dir ('build-dir') {
|
||||||
checkout poll: false, scm: scmGit([
|
// checkout poll: false, scm: scmGit([
|
||||||
branches: [[name: 'main']],
|
// branches: [[name: 'main']],
|
||||||
userRemoteConfigs: [[credentialsId: 'gitea-jenkins-user-token', url: 'https://gitea.fahrecker.com/andreas-personal/AndysAdguardHomeBlocklist.git']]
|
// userRemoteConfigs: [[credentialsId: 'gitea-jenkins-user-token', url: 'https://gitea.fahrecker.com/andreas-personal/AndysAdguardHomeBlocklist.git']]
|
||||||
])
|
// ])
|
||||||
|
// sh 'git checkout main'
|
||||||
|
// sh 'pwd'
|
||||||
|
// }
|
||||||
sh 'git checkout main'
|
sh 'git checkout main'
|
||||||
sh 'pwd'
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('NPM Install') {
|
stage('NPM Install') {
|
||||||
@ -27,10 +28,10 @@ pipeline {
|
|||||||
branch 'main'
|
branch 'main'
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
dir ('build-dir') {
|
// dir ('build-dir') {
|
||||||
sh 'pwd'
|
sh 'pwd'
|
||||||
sh 'npm clean-install'
|
sh 'npm clean-install'
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('Compile Adblock List') {
|
stage('Compile Adblock List') {
|
||||||
@ -39,14 +40,14 @@ pipeline {
|
|||||||
branch 'main'
|
branch 'main'
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
dir ('build-dir') {
|
// dir ('build-dir') {
|
||||||
sh '''
|
sh '''
|
||||||
mkdir -p out
|
mkdir -p out
|
||||||
npm run compile:test
|
npm run compile:test
|
||||||
git add out/andysadguardhomeblocklist.txt
|
git add out/andysadguardhomeblocklist.txt
|
||||||
git commit -m "Update Compiled Adblock List"
|
git commit -m "Update Compiled Adblock List"
|
||||||
'''
|
'''
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stage('git push') {
|
stage('git push') {
|
||||||
@ -55,7 +56,7 @@ pipeline {
|
|||||||
branch 'main'
|
branch 'main'
|
||||||
}
|
}
|
||||||
steps {
|
steps {
|
||||||
dir ('build-dir') {
|
// dir ('build-dir') {
|
||||||
withCredentials([
|
withCredentials([
|
||||||
gitUsernamePassword(credentialsId: 'gitea-jenkins-user-token')
|
gitUsernamePassword(credentialsId: 'gitea-jenkins-user-token')
|
||||||
]) {
|
]) {
|
||||||
@ -64,7 +65,7 @@ pipeline {
|
|||||||
git push
|
git push
|
||||||
'''
|
'''
|
||||||
}
|
}
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user