diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 00000000..9c94cca6 --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,35 @@ +#!/usr/bin/env groovy +pipeline { + agent any + tools { nodejs "node" } + options { + buildDiscarder(logRotator(daysToKeepStr: '90', artifactNumToKeepStr: '3')) + } + stages { + stage('Preflight') { + steps { + echo sh(returnStdout: true, script: 'env') + sh 'node -v' + } + } + stage('Init') { + steps { + sh 'git log --reverse -1' + sh 'npm --version' + sh 'npm run init' + } + } + stage('Build') { + steps { + sh 'mkdir -p ../node.js_Build' + sh 'wget -O ../node.js_Build/funcs.js https://raw.githubusercontent.com/Kiuryy/node.js_Build/master/funcs.js' + sh 'npm run release' + } + } + } + post { + always { + archiveArtifacts artifacts: '*.zip' + } + } +} \ No newline at end of file