Skip to content

Commit ce877c6

Browse files
authored
Merge branch 'dev' into dm/application-sample
2 parents da41266 + 0e83a21 commit ce877c6

File tree

31,550 files changed

+5963438
-3110557
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

31,550 files changed

+5963438
-3110557
lines changed
Lines changed: 102 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,102 @@
1+
# Copyright (c) Microsoft Corporation. All rights reserved.
2+
# Licensed under the MIT License.
3+
4+
# Generates a release build artifact (nuget) from HEAD of master for auth module.
5+
name: $(BuildDefinitionName)_$(SourceBranchName)_$(Date:yyyyMMdd)$(Rev:.r)
6+
7+
pool:
8+
vmImage: "windows-latest"
9+
10+
variables:
11+
BRANCH: 'weeklyOpenApiDocsDownload'
12+
GitUserEmail: '[email protected]'
13+
GitUserName: 'Microsoft Graph DevX Tooling'
14+
BaseBranch: 'dev'
15+
16+
schedules:
17+
- cron: "0 0 * * WED" # Run Every Wednesday
18+
displayName: "Weekly OpenApiDocs Download and PR"
19+
branches:
20+
include:
21+
- dev
22+
always: true
23+
24+
steps:
25+
- checkout: self
26+
persistCredentials: true
27+
clean: true
28+
fetchDepth: 1
29+
30+
- task: securedevelopmentteam.vss-secure-development-tools.build-task-credscan.CredScan@2
31+
displayName: 'Run CredScan'
32+
inputs:
33+
debugMode: false
34+
35+
- task: PowerShell@2
36+
displayName: "Compute Branch"
37+
inputs:
38+
targetType: inline
39+
script: |
40+
$branch = "{0}.{1}" -f "weeklyOpenApiDocsDownload", (Get-Date -Format yyyyMMdd)
41+
Write-Host "##vso[task.setvariable variable=BRANCH;]$branch"
42+
43+
- task: PowerShell@2
44+
displayName: "Configure User"
45+
inputs:
46+
targetType: 'inline'
47+
script: |
48+
git config --global user.email '$(GitUserEmail)'
49+
git config --global user.name '$(GitUserName)'
50+
51+
- task: PowerShell@2
52+
displayName: "Show Directory"
53+
inputs:
54+
targetType: 'inline'
55+
script: |
56+
ls $(System.DefaultWorkingDirectory)
57+
ls $(System.DefaultWorkingDirectory)/tools
58+
59+
- task: PowerShell@2
60+
displayName: Download v1.0 OpenApiDocs
61+
continueOnError: false
62+
inputs:
63+
filePath: '$(System.DefaultWorkingDirectory)/tools/UpdateOpenApi.ps1'
64+
pwsh: true
65+
66+
- task: PowerShell@2
67+
displayName: Download beta OpenApiDocs
68+
continueOnError: false
69+
inputs:
70+
filePath: '$(System.DefaultWorkingDirectory)/tools/UpdateOpenApi.ps1'
71+
arguments: '-BetaGraphVersion'
72+
pwsh: true
73+
74+
- task: Bash@3
75+
displayName : "Create PR $(BRANCH)"
76+
inputs:
77+
targetType: 'inline'
78+
script: |
79+
git status
80+
git checkout $(BaseBranch)
81+
git branch $(BRANCH)
82+
git checkout $(BRANCH)
83+
git status
84+
85+
- task: Bash@3
86+
displayName : "Commit Downloaded Files"
87+
env:
88+
GITHUB_TOKEN: $(GITHUB_TOKEN)
89+
inputs:
90+
targetType: 'inline'
91+
script: |
92+
git status
93+
git add .
94+
git commit -m 'Weekly OpenApiDocs Download'
95+
git status
96+
git push --set-upstream origin $(BRANCH)
97+
git status
98+
99+
# References
100+
# [0] https://help.github.com/en/actions/configuring-and-managing-workflows/using-environment-variables
101+
# [1] https://hub.github.com/hub-pull-request.1.html
102+
# https://help.github.com/en/actions/configuring-and-managing-workflows/authenticating-with-the-github_token

.azure-pipelines/generate-auth-module.yml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,17 @@ jobs:
2121
displayName: MS Graph PS SDK Auth Generation
2222
timeoutInMinutes: 300
2323
pool:
24-
name: Microsoft Graph
25-
demands: 'Agent.Name -equals Local-Agent'
24+
vmImage: 'windows-latest'
2625

2726
steps:
2827
- task: securedevelopmentteam.vss-secure-development-tools.build-task-credscan.CredScan@2
2928
displayName: 'Run CredScan'
3029
inputs:
3130
debugMode: false
3231

32+
- task: NuGetToolInstaller@1
33+
displayName: 'Install Nuget'
34+
3335
- task: PowerShell@2
3436
displayName: 'Generate and Build Auth Module'
3537
inputs:

.azure-pipelines/generate-beta-modules.yml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,27 +22,36 @@ variables:
2222
jobs:
2323
- job: MSGraphPSSDKGeneration
2424
displayName: MS Graph PS SDK Beta Generation
25-
timeoutInMinutes: 300
25+
timeoutInMinutes: 600
2626
pool:
27-
name: Microsoft Graph
28-
demands: 'Agent.Name -equals Local-Agent'
27+
vmImage: 'windows-latest'
28+
2929
steps:
3030
- task: securedevelopmentteam.vss-secure-development-tools.build-task-credscan.CredScan@2
3131
displayName: 'Run CredScan'
3232
inputs:
3333
debugMode: false
34-
34+
35+
# Install Node
36+
- task: NodeTool@0
37+
displayName: Node install
38+
inputs:
39+
versionSpec: '13.14.0'
40+
3541
- task: Npm@1
3642
displayName: 'Install AutoRest'
3743
inputs:
3844
command: 'custom'
39-
customCommand: 'install -g @autorest/autorest'
45+
customCommand: 'install -g autorest'
46+
47+
- task: NuGetToolInstaller@1
48+
displayName: 'Install Nuget'
4049

4150
- task: PowerShell@2
4251
displayName: 'Build Auth Modules'
4352
inputs:
4453
filePath: '$(System.DefaultWorkingDirectory)/tools/GenerateAuthenticationModule.ps1'
45-
arguments: '-RepositoryApiKey $(Api_Key) -ArtifactsLocation $(Build.ArtifactStagingDirectory) -Build -EnableSigning'
54+
arguments: '-RepositoryApiKey $(Api_Key) -ArtifactsLocation $(Build.ArtifactStagingDirectory) -Build -BuildWhenEqual -EnableSigning'
4655
pwsh: true
4756

4857
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1
@@ -122,7 +131,7 @@ jobs:
122131
displayName: 'Generate and Build Graph Resource Modules'
123132
inputs:
124133
filePath: '$(System.DefaultWorkingDirectory)/tools/GenerateModules.ps1'
125-
arguments: '-RepositoryApiKey $(Api_Key) -ArtifactsLocation $(Build.ArtifactStagingDirectory)\$(GRAPH_VERSION)\ -UseLocalDoc -BetaGraphVersion -Build -EnableSigning'
134+
arguments: '-RepositoryApiKey $(Api_Key) -ArtifactsLocation $(Build.ArtifactStagingDirectory)\$(GRAPH_VERSION)\ -Build -EnableSigning'
126135
pwsh: true
127136

128137
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1

.azure-pipelines/generate-beta-rollup-module.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,22 @@ jobs:
1616
displayName: MS Graph PS SDK Roll-Up Generation
1717
timeoutInMinutes: 300
1818
pool:
19-
name: Microsoft Graph
20-
demands: 'Agent.Name -equals Local-Agent'
19+
vmImage: 'windows-latest'
2120

2221
steps:
2322
- task: securedevelopmentteam.vss-secure-development-tools.build-task-credscan.CredScan@2
2423
displayName: 'Run CredScan'
2524
inputs:
2625
debugMode: false
2726

27+
- task: NuGetToolInstaller@1
28+
displayName: 'Install Nuget'
29+
2830
- task: PowerShell@2
2931
displayName: 'Generate and Build Roll-Up Module'
3032
inputs:
3133
filePath: '$(System.DefaultWorkingDirectory)/tools/GenerateRollUpModule.ps1'
32-
arguments: '-RepositoryApiKey $(Api_Key) -ArtifactsLocation $(Build.ArtifactStagingDirectory)/$(GRAPH_VERSION)/ -BetaGraphVersion'
34+
arguments: '-RepositoryApiKey $(Api_Key) -ArtifactsLocation $(Build.ArtifactStagingDirectory)/$(GRAPH_VERSION)/'
3335
pwsh: true
3436

3537
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@1

0 commit comments

Comments
 (0)