Skip to content

Commit a9ebe75

Browse files
Merge branch 'main' into refactor/consolidate-dependabot-remove-pom
2 parents a2c0bfd + cc2ff51 commit a9ebe75

4 files changed

Lines changed: 59 additions & 14 deletions

File tree

.azure-pipelines/daily-ci-build.yml

Lines changed: 22 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ extends:
2121
parameters:
2222
pool:
2323
name: Azure-Pipelines-1ESPT-ExDShared
24+
image: ubuntu-latest
2425
os: linux
2526
sdl:
2627
sourceAnalysisPool:
@@ -42,17 +43,26 @@ extends:
4243
- checkout: self
4344
submodules: recursive
4445

45-
- task: JavaToolInstaller@0
46-
displayName: Set up Java
46+
- script: |
47+
sed -i "/com.github.spotbugs/d" build.gradle
48+
sed -i "/org.sonarqube/d" build.gradle
49+
sed -i "/spotbugsMain/,/^}/d" build.gradle
50+
sed -i "/spotbugsTest/,/^}/d" build.gradle
51+
sed -i "/sonarqube {/,/^}/d" build.gradle
52+
sed -i "/mavenCentral()/d" build.gradle
53+
sed -i "/gradlePluginPortal()/d" settings.gradle
54+
sed -i "/mavenCentral()/d" settings.gradle
55+
displayName: Strip plugins and public repos for network-isolated build
56+
57+
- task: Gradle@4
58+
displayName: Build and Test SDK
4759
inputs:
48-
versionSpec: '17'
60+
gradleWrapperFile: 'gradlew'
61+
workingDirectory: '$(Build.SourcesDirectory)'
62+
tasks: 'assemble test'
63+
options: '--no-daemon -PGraphDeveloperExperiencesPublicPassword=$(ARTIFACTS_PAT)'
64+
publishJUnitResults: true
65+
testResultsFiles: '**/TEST-*.xml'
66+
javaHomeOption: 'JDKVersion'
67+
jdkVersionOption: '1.17'
4968
jdkArchitectureOption: 'x64'
50-
jdkSourceOption: 'PreInstalled'
51-
52-
- script: chmod +x gradlew && ./gradlew assemble
53-
displayName: Build SDK
54-
workingDirectory: $(Build.SourcesDirectory)
55-
56-
- script: ./gradlew test
57-
displayName: Run unit tests
58-
workingDirectory: $(Build.SourcesDirectory)

build.gradle

Lines changed: 18 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ plugins {
55
id 'maven-publish'
66
id 'signing'
77
id 'jacoco'
8-
id 'com.github.spotbugs' version '6.2.5'
9-
id "org.sonarqube" version "7.2.2.6593"
8+
id 'com.github.spotbugs' version '6.5.4'
9+
id "org.sonarqube" version "7.3.0.8198"
1010

1111
}
1212

@@ -68,6 +68,14 @@ sourceSets {
6868
repositories {
6969
// You can declare any Maven/Ivy/file repository here.
7070
mavenCentral()
71+
maven {
72+
url 'https://microsoftgraph.pkgs.visualstudio.com/0985d294-5762-4bc2-a565-161ef349ca3e/_packaging/GraphDeveloperExperiences_Public/maven/v1'
73+
name 'GraphDeveloperExperiencesPublic'
74+
credentials(PasswordCredentials)
75+
authentication {
76+
basic(BasicAuthentication)
77+
}
78+
}
7179
}
7280

7381
apply from: "gradle/dependencies.gradle"
@@ -118,6 +126,14 @@ publishing {
118126
name = "ADO"
119127
url = layout.buildDirectory.dir("publishing-repository")
120128
}
129+
maven {
130+
url 'https://microsoftgraph.pkgs.visualstudio.com/0985d294-5762-4bc2-a565-161ef349ca3e/_packaging/GraphDeveloperExperiences_Public/maven/v1'
131+
name 'GraphDeveloperExperiencesPublic'
132+
credentials(PasswordCredentials)
133+
authentication {
134+
basic(BasicAuthentication)
135+
}
136+
}
121137
}
122138
}
123139

gradle.properties

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,7 @@ mavenArtifactSuffix =
3737
#enable mavenCentralPublishingEnabled to publish to maven central
3838
mavenCentralSnapshotArtifactSuffix = -SNAPSHOT
3939
mavenCentralPublishingEnabled=false
40+
41+
# Azure Artifacts CFS feed credentials
42+
GraphDeveloperExperiencesPublicUsername=microsoftgraph
43+
GraphDeveloperExperiencesPublicPassword=PERSONAL_ACCESS_TOKEN

settings.gradle

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,18 @@
1+
pluginManagement {
2+
repositories {
3+
gradlePluginPortal()
4+
mavenCentral()
5+
maven {
6+
url 'https://microsoftgraph.pkgs.visualstudio.com/0985d294-5762-4bc2-a565-161ef349ca3e/_packaging/GraphDeveloperExperiences_Public/maven/v1'
7+
name 'GraphDeveloperExperiencesPublic'
8+
credentials(PasswordCredentials)
9+
authentication {
10+
basic(BasicAuthentication)
11+
}
12+
}
13+
}
14+
}
15+
116
/*
217
* This file was generated by the Gradle 'init' task.
318
*

0 commit comments

Comments
 (0)