no electron

This commit is contained in:
Primakov Alexandr Alexandrovich 2020-09-26 14:28:11 +03:00
parent a95d65df28
commit 1f078138c9
3 changed files with 25 additions and 4 deletions

View File

@ -1,3 +1,7 @@
stage ('build') { stage ('build') {
try {
sh 'npm run build' sh 'npm run build'
} catch (error) {
echo error
}
} }

17
install/no-electron/Jenkinsfile vendored Normal file
View File

@ -0,0 +1,17 @@
import groovy.json.JsonBuilder
import groovy.json.JsonSlurper
import groovy.json.JsonOutput
import java.util.HashMap
import groovy.json.*
stage('install:no:electron') {
echo 'Пробуем убрать electron из зависимостей)'
def elString = sh(returnStdout: true, script: "cat ./package.json | grep electron\\\" || echo 'empty'")
echo elString
if (elString.contains(',')) {
sh "mv ./package.json ./tmp-package.json"
echo "Electron найден. Удаляем..."
sh "cat ./tmp-package.json | grep -v electron\\\" > ./package.json"
}
}

6
stats/Jenkinsfile vendored
View File

@ -2,8 +2,8 @@ stage('stats') {
echo 'checking node and npm versions' echo 'checking node and npm versions'
sh 'node -v' sh 'node -v'
sh 'npm -v' sh 'npm -v'
// sh 'ls -a' sh 'ls -a'
// sh 'df -h' sh 'df -h'
// sh 'free -m' sh 'free -m'
// sh 'vmstat -s' // sh 'vmstat -s'
} }