2022-04-17 06:37:34 +00:00
|
|
|
pipeline {
|
2022-04-16 08:22:01 +00:00
|
|
|
agent any
|
2022-04-17 06:37:34 +00:00
|
|
|
stages {
|
2022-04-16 08:22:01 +00:00
|
|
|
stage("install") {
|
|
|
|
steps {
|
|
|
|
nodejs('NodeJS (17.4.0)') {
|
|
|
|
sh "npm install"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
stage("build") {
|
|
|
|
steps {
|
|
|
|
nodejs('NodeJS (17.4.0)') {
|
2022-04-18 01:12:13 +00:00
|
|
|
sh "npm run build:dev"
|
2022-04-16 08:22:01 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
stage("test") {
|
|
|
|
steps {
|
|
|
|
nodejs('NodeJS (17.4.0)') {
|
|
|
|
sh "npm run test"
|
|
|
|
}
|
2022-04-17 06:37:34 +00:00
|
|
|
junit 'junit/*.xml'
|
2022-04-16 08:22:01 +00:00
|
|
|
}
|
|
|
|
}
|
2022-04-16 08:36:22 +00:00
|
|
|
stage("archive product") {
|
|
|
|
steps {
|
|
|
|
archiveArtifacts artifacts: 'dist/audioshowkit.js', followSymlinks: false
|
|
|
|
}
|
|
|
|
}
|
2022-04-18 01:47:16 +00:00
|
|
|
stage("publish") {
|
|
|
|
parallel {
|
|
|
|
stage("setup showcase") {
|
|
|
|
stages {
|
|
|
|
stage("install showcase") {
|
|
|
|
steps {
|
|
|
|
dir('./showcase/') {
|
|
|
|
nodejs('NodeJS (17.4.0)') {
|
|
|
|
sh "npm i"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
stage("build showcase") {
|
|
|
|
steps {
|
|
|
|
dir('./showcase/') {
|
|
|
|
nodejs('NodeJS (17.4.0)') {
|
|
|
|
sh "npm run build"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
stage("deploy showcase") {
|
|
|
|
steps {
|
|
|
|
publishHTML([allowMissing: false, alwaysLinkToLastBuild: false, keepAll: false, reportDir: 'showcase/dist', reportFiles: 'index.html', reportName: 'AudioShowKit Demo', reportTitles: ''])
|
|
|
|
}
|
|
|
|
}
|
2022-04-17 23:47:24 +00:00
|
|
|
}
|
|
|
|
}
|
2022-04-18 01:47:16 +00:00
|
|
|
stage("generate docs") {
|
|
|
|
steps {
|
|
|
|
nodejs('NodeJS (17.4.0)') {
|
|
|
|
sh "npm run docs"
|
|
|
|
}
|
|
|
|
publishHTML([allowMissing: false, alwaysLinkToLastBuild: false, keepAll: false, reportDir: 'docs', reportFiles: 'index.html', reportName: 'AudioShowKit JSDocs', reportTitles: ''])
|
|
|
|
}
|
2022-04-16 08:22:01 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|