Skip to content

Commit 404957f

Browse files
committed
added the maven preview and release stages to buildAndPackage.yml as well as github release stage.
1 parent c9c2f8c commit 404957f

11 files changed

Lines changed: 107 additions & 7 deletions

File tree

‎.azure-pipelines/buildAndPackage.yml‎

Lines changed: 31 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,34 @@ pr: none
3030
pool:
3131
vmImage: windows-latest
3232

33-
steps:
34-
- template: templates/checkout-and-credscan.yml
35-
- template: templates/install-java.yml
36-
- template: templates/secure-files.yml
37-
- template: templates/build-and-coverage.yml
38-
- template: templates/publish-artefacts.yml
39-
- template: templates/alert-failure.yml
33+
stages:
34+
- stage: Build-Stage
35+
jobs:
36+
- job: Build
37+
steps:
38+
- template: templates/build-stage/checkout-and-credscan.yml
39+
- template: templates/build-stage/install-java.yml
40+
- template: templates/build-stage/secure-files.yml
41+
- template: templates/build-stage/build-and-coverage.yml
42+
- template: templates/build-stage/publish-artefacts.yml
43+
- template: templates/alert-failure.yml
44+
- stage: Maven-Preview-Stage
45+
jobs:
46+
- job: Maven-Preview
47+
steps:
48+
- template: templates/maven-preview-stage/secure-files.yml
49+
- template: templates/maven-preview-stage/copy-and-build.yml
50+
- template: templates/alert-failure.yml
51+
- stage: Maven-Release-Stage
52+
jobs:
53+
- job: Maven-Release
54+
steps:
55+
- template: templates/maven-release-stage/secure-files.yml
56+
- template: templates/maven-release-stage/copy-and-build.yml
57+
- template: templates/alert-failure.yml
58+
- stage: Github-Release-Stage
59+
jobs:
60+
- job: Github-Release
61+
steps:
62+
- template: templates/github-release-stage/version-and-release.yml
63+
- template: templates/alert-failure.yml

.azure-pipelines/templates/build-and-coverage.yml renamed to .azure-pipelines/templates/build-stage/build-and-coverage.yml

File renamed without changes.

.azure-pipelines/templates/checkout-and-credscan.yml renamed to .azure-pipelines/templates/build-stage/checkout-and-credscan.yml

File renamed without changes.
File renamed without changes.

.azure-pipelines/templates/publish-artefacts.yml renamed to .azure-pipelines/templates/build-stage/publish-artefacts.yml

File renamed without changes.
File renamed without changes.
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
steps:
2+
- task: PowerShell@2
3+
inputs:
4+
filePath: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop/Scripts/getLatestVersion.ps1'
5+
arguments: '-propertiesPath "$(PROPERTIES_PATH)"'
6+
7+
- task: GitHubRelease@1
8+
inputs:
9+
gitHubConnection: 'ramsessanchez'
10+
repositoryName: '$(Build.Repository.Name)'
11+
action: 'create'
12+
target: '$(Build.SourceVersion)'
13+
tagSource: 'userSpecifiedTag'
14+
tag: '$(VERSION_STRING)'
15+
assets: |
16+
!**/**
17+
$(Build.ArtifactStagingDirectory)/*
18+
changeLogCompareToRelease: 'lastFullRelease'
19+
changeLogType: 'commitBased'
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
steps:
2+
- task: CopyFiles@2
3+
inputs:
4+
SourceFolder: '$(Agent.TempDirectory)'
5+
Contents: '**'
6+
TargetFolder: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop/'
7+
8+
- task: Gradle@2
9+
inputs:
10+
gradleWrapperFile: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop/gradlew'
11+
workingDirectory: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop'
12+
options: '-x jar -x javadoc -x javadocJar -x compileJava -x processResources -x classes -x sourceJar'
13+
tasks: 'publishSnapshotPublicationToSonatypeSnapshotRepository'
14+
publishJUnitResults: true
15+
testResultsFiles: '**/TEST-*.xml'
16+
javaHomeOption: 'JDKVersion'
17+
sonarQubeRunAnalysis: false
18+
spotBugsAnalysis: false
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
steps:
2+
- task: DownloadSecureFile@1
3+
inputs:
4+
secureFile: 'local.properties'
5+
retryCount: '5'
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
steps:
2+
- task: CopyFiles@2
3+
inputs:
4+
SourceFolder: '$(Agent.TempDirectory)'
5+
Contents: '**'
6+
TargetFolder: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop'
7+
8+
- task: Gradle@2
9+
inputs:
10+
gradleWrapperFile: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop/gradlew'
11+
workingDirectory: '$(System.DefaultWorkingDirectory)/_msgraph-sdk-java-core build and package/drop'
12+
options: '-x jar -x javadoc -x javadocJar -x compileJava -x processResources -x classes -x sourceJar'
13+
tasks: 'publishMavenCentralReleasePublicationToSonatypeRepository'
14+
publishJUnitResults: true
15+
testResultsFiles: '**/TEST-*.xml'
16+
javaHomeOption: 'JDKVersion'
17+
sonarQubeRunAnalysis: false
18+
spotBugsAnalysis: false

0 commit comments

Comments
 (0)