fix(buddybook): Jenkinsfile

This commit is contained in:
Danish Arora 2024-10-29 16:01:56 +05:30
parent b7b6672196
commit d05bbd6cb8
No known key found for this signature in database
GPG Key ID: 1C6EF37CDAE1426E
1 changed files with 11 additions and 1 deletions

12
ci/Jenkinsfile vendored
View File

@ -44,7 +44,7 @@ pipeline {
stage('dogfooding') { steps { script { buildExample() } } }
stage('message-monitor') { steps { script { buildExample() } } }
stage('flush-notes') { steps { script { buildNextJSExample() } } }
stage('buddybook') { steps { script { buildExample() } } }
stage('buddybook') { steps { script { buildViteExample() } } }
}
}
@ -89,6 +89,16 @@ def buildNextJSExample(example=STAGE_NAME) {
}
}
def buildViteExample(example=STAGE_NAME) {
def dest = "${WORKSPACE}/build/docs/${example}"
dir("examples/${example}") {
sh 'npm install --silent'
sh 'npm run build'
sh "mkdir -p ${dest}"
sh "cp -r dist/. ${dest}"
}
}
def copyExample(example=STAGE_NAME) {
def source = "examples/${example}"
def dest = "build/docs/${example}"