From ad1f98085042b8cf12372c43d329c0601fee8d02 Mon Sep 17 00:00:00 2001 From: "U:Bodigat" <89653017+ubodigat@users.noreply.github.com> Date: Sat, 29 Nov 2025 08:54:00 +0100 Subject: [PATCH] Update publish workflow for VS Code extension --- .github/workflows/publish.yml | 29 ++++++++--------------------- 1 file changed, 8 insertions(+), 21 deletions(-) diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 01a59f3..964f841 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,13 +1,10 @@ name: Publish VS Code Extension on: - release: - types: [published] - workflow_dispatch: permissions: - contents: read + contents: write jobs: build: @@ -21,8 +18,7 @@ jobs: - name: Install Node.js uses: actions/setup-node@v4 with: - node-version: 18 - cache: npm + node-version: 20 - name: Install dependencies run: npm ci @@ -46,7 +42,6 @@ jobs: name: Attach VSIX to GitHub Release needs: build runs-on: ubuntu-latest - permissions: contents: write @@ -55,12 +50,11 @@ jobs: uses: actions/download-artifact@v4 with: name: extension - path: dist - - name: Create / update GitHub Release with VSIX - uses: softprops/action-gh-release@v2 + - name: Create GitHub Release + uses: softprops/action-gh-release@v1 with: - files: dist/*.vsix + files: "*.vsix" env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -69,17 +63,11 @@ jobs: needs: release runs-on: ubuntu-latest - permissions: - contents: read - steps: - - name: Checkout repository - uses: actions/checkout@v4 - - name: Install Node.js uses: actions/setup-node@v4 with: - node-version: 18 + node-version: 20 - name: Install vsce run: npm install -g @vscode/vsce @@ -88,9 +76,8 @@ jobs: uses: actions/download-artifact@v4 with: name: extension - path: dist - name: Publish to VSCode Marketplace - run: vsce publish --packagePath dist/*.vsix + run: vsce publish --packagePath *.vsix env: - VSCE_PAT: ${{ secrets.VSCE_PAT }} \ No newline at end of file + VSCE_PAT: ${{ secrets.VSCE_PAT }}