-
Notifications
You must be signed in to change notification settings - Fork 7
/
Jenkinsfile.webpack
52 lines (42 loc) · 1.02 KB
/
Jenkinsfile.webpack
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
@Library('conservify') _
properties([
disableConcurrentBuilds(),
buildDiscarder(logRotator(numToKeepStr: '5'))
])
timestamps {
node ("jenkins-aws-ubuntu") {
try {
def scmInfo
stage ('git') {
scmInfo = checkout scm
}
def (remote, branch) = scmInfo.GIT_BRANCH.tokenize('/')
stage ('npm') {
sh "rm -rf node_modules/*/.git node_modules/fk-*-protocol"
sh "npm install"
sh "cp app/secrets.ts.release app/secrets.ts"
}
stage ('tests') {
sh "make test"
}
stage ('checks') {
sh "make checks"
}
stage ('webpack:ios') {
withEnv(["GIT_LOCAL_BRANCH=${branch}"]) {
sh "make ios-webpack"
}
}
stage ('webpack:android') {
withEnv(["GIT_LOCAL_BRANCH=${branch}"]) {
sh "make android-webpack"
}
}
notifySuccess()
}
catch (Exception e) {
notifyFailure()
throw e;
}
}
}