31 lines
846 B
Groovy
31 lines
846 B
Groovy
pipeline {
|
|
agent linux // You can specify 'linux' if you specifically need a Linux agent
|
|
|
|
stages {
|
|
stage('Build') {
|
|
steps {
|
|
sh 'dart doc'
|
|
}
|
|
}
|
|
|
|
stage('Test') {
|
|
steps {
|
|
sh 'dart test'
|
|
}
|
|
}
|
|
|
|
stage('Deploy') {
|
|
steps {
|
|
sh 'dart pub publish'
|
|
sh 'git clone git@github.com:ariascreations/ServerCode'
|
|
sh 'rsync -a --progress -h --delete doc/api/ ServerCode/api.zontreck.com/dartdocs/libac/'
|
|
dir('ServerCode') {
|
|
sh 'git add --all .'
|
|
sh 'git commit -m "[BOT] Publish LibAC DartDocs"'
|
|
sh 'git push --all'
|
|
}
|
|
sh 'rm -rf ServerCode'
|
|
}
|
|
}
|
|
}
|
|
}
|