diff --git a/.github/workflows/vsix-release.yml b/.github/workflows/vsix-release.yml index 8e5fe519..34b8f9f8 100644 --- a/.github/workflows/vsix-release.yml +++ b/.github/workflows/vsix-release.yml @@ -30,9 +30,20 @@ jobs: - name: Build run: msbuild /p:Configuration=Release + - name: Resolve VSIX file path + shell: pwsh + run: | + $vsixFile = Get-ChildItem -Path VSIX -Filter *.vsix -Recurse | Select-Object -First 1 -ExpandProperty FullName + if (-not $vsixFile) { + Write-Host "::error::No VSIX file was produced by the build." + exit 1 + } + Write-Host "VSIX file: $vsixFile" + "VSIX_FILE=$vsixFile" | Out-File -FilePath $env:GITHUB_ENV -Append + - name: Publish to Marketplace uses: madskristensen/publish-marketplace@v2 with: - extension-file: '**/*.vsix' + extension-file: ${{ env.VSIX_FILE }} publish-manifest-file: vs-publish.json personal-access-code: ${{ secrets.VS_MARKETPLACE_TOKEN }}