forked from OfficeDev/ews-java-api
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjenkinsfile
More file actions
45 lines (42 loc) · 1.13 KB
/
jenkinsfile
File metadata and controls
45 lines (42 loc) · 1.13 KB
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
pipeline {
agent any
tools {
maven "Maven 3.5.0"
jdk "OpenJDK 11"
}
parameters {
choice(name: 'MAVEN_STAGE', choices: ['package', 'deploy'], description: '''
Whether to package or deploy the plugin:
package - Package the plugin for retrieval from the Jenkins job's workspace
deploy - Package and deploy the plugin to the configured Maven repository (presumably x360Cloud's internal Nexus repository)
''')
}
stages {
stage('Clean Workspace') {
steps {
deleteDir()
}
}
stage ('checkout') {
steps {
checkout([
$class: 'GitSCM',
branches: [[name: '${GIT_TAG}']],
userRemoteConfigs: [
[
url: 'git@github.com:Axcient/cf-ews-java-api.git',
credentialsId: '232cb6c4-dc4c-4c63-a22c-8cabd8278c26'
]
]
])
}
}
stage ('build') {
steps {
script{
sh "mvn clean -X ${MAVEN_STAGE} -Djacoco.skip=true -DNEXUS_SNAPSHOT_URL=$NEXUS_SNAPSHOT_URL -DNEXUS_RELEASE_URL=$NEXUS_RELEASE_URL"
}
}
}
}
}