Skip to content

Commit 7fff0db

Browse files
Copilotraych1
authored andcommitted
Merge path resolution into tsp-client execution step
Co-authored-by: raych1 <[email protected]>
1 parent 7ca660a commit 7fff0db

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

eng/common/pipelines/templates/archetype-typespec-emitter.yml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -269,25 +269,21 @@ extends:
269269
if (-not [System.IO.Path]::IsPathRooted($emitterPath)) {
270270
$emitterPath = Join-Path '$(Build.SourcesDirectory)' $emitterPath
271271
}
272-
Write-Host "##vso[task.setvariable variable=ResolvedEmitterPath]$emitterPath"
273-
displayName: Resolve emitter package path
274-
workingDirectory: $(Build.SourcesDirectory)
275272
276-
- pwsh: |
277273
Write-Host "Overrides location: $(buildArtifactsPath)/packages/overrides.json"
278-
Write-Host "Resolved emitter package path: $(ResolvedEmitterPath)"
274+
Write-Host "Resolved emitter package path: $emitterPath"
279275
280276
if (Test-Path -Path '$(buildArtifactsPath)/packages/overrides.json') {
281277
Write-Host "Using overrides.json to generate emitter-package.json"
282278
npm exec --no -- tsp-client generate-config-files `
283279
--package-json '$(buildArtifactsPath)/lock-files/package.json' `
284-
--emitter-package-json-path '$(ResolvedEmitterPath)' `
280+
--emitter-package-json-path "$emitterPath" `
285281
--overrides '$(buildArtifactsPath)/packages/overrides.json'
286282
} else {
287283
Write-Host "No overrides.json found. Running tsp-client without overrides."
288284
npm exec --no -- tsp-client generate-config-files `
289285
--package-json '$(buildArtifactsPath)/lock-files/package.json' `
290-
--emitter-package-json-path '$(ResolvedEmitterPath)'
286+
--emitter-package-json-path "$emitterPath"
291287
}
292288
displayName: Generate emitter-package.json and emitter-package-lock files
293289
workingDirectory: $(Build.SourcesDirectory)/eng/common/tsp-client

0 commit comments

Comments
 (0)