Skip to content

Commit

Permalink
build: Update vscode-java-test-nightly.yml for api scan (#1669)
Browse files Browse the repository at this point in the history
Co-authored-by: Sheng Chen <[email protected]>
  • Loading branch information
testforstephen and jdneo authored Mar 4, 2024
1 parent 6fe3a0c commit af08baf
Showing 1 changed file with 23 additions and 4 deletions.
27 changes: 23 additions & 4 deletions .azure-pipelines/vscode-java-test-nightly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ extends:
parameters:
pool:
name: 1ES_JavaTooling_Pool
image: 1ES_JavaTooling_Ubuntu-2004
os: linux
image: 1ES_JavaTooling_Windows_2022
os: windows
sdl:
sourceAnalysisPool:
name: 1ES_JavaTooling_Pool
Expand Down Expand Up @@ -76,7 +76,7 @@ extends:
- task: SFP.build-tasks.custom-build-task-1.EsrpCodeSigning@2
displayName: ESRP CodeSigning
inputs:
ConnectedServiceName: vscjavaci_codesign
ConnectedServiceName: vscjavaci_esrp_codesign
FolderPath: server
Pattern: com.microsoft.java.test.*.jar
signConfigType: inlineSignParams
Expand All @@ -103,7 +103,7 @@ extends:
- task: CmdLine@2
displayName: Replace AI Key
inputs:
script: npx [email protected] -I -f package.json -e "this.aiKey=\"$AI_KEY\""
script: npx [email protected] -I -f package.json -e "this.aiKey=\"%AI_KEY%\""
- task: Bash@3
displayName: Bash Script
inputs:
Expand All @@ -115,6 +115,25 @@ extends:
displayName: vsce package --pre-release
inputs:
script: npx @vscode/vsce@latest package --pre-release
### Copy files for APIScan
- task: CopyFiles@2
displayName: "Copy Files for APIScan"
inputs:
Contents: "*.vsix"
TargetFolder: $(Agent.TempDirectory)/APIScanFiles
condition: and(succeeded(), ne(variables['DisableAPIScan'], 'true'))
### Run latest version of APIScan listed at https://www.1eswiki.com/wiki/APIScan_Build_Task
- task: APIScan@2
displayName: Run APIScan
inputs:
softwareFolder: $(Agent.TempDirectory)/APIScanFiles
softwareName: "vscode-java-test"
softwareVersionNum: "$(Build.BuildId)"
isLargeApp: false
toolVersion: "Latest"
condition: and(succeeded(), ne(variables['DisableAPIScan'], 'true'))
env:
AzureServicesAuthConnectionString: runAs=App;AppId=$(ApiScanClientId);TenantId=$(ApiScanTenant);AppKey=$(ApiScanSecret)
- task: CopyFiles@2
displayName: "Copy Files to: $(Build.ArtifactStagingDirectory)"
inputs:
Expand Down

0 comments on commit af08baf

Please sign in to comment.