Skip to content

Commit 9e89fac

Browse files
committed
Separate VSCode publish jobs
- Split publish-to-open-vsx and publish-to-vs-marketplace into separate jobs - Ensure the same VSIX file is published to both registries - Build and Open VSX publish happen together, VS Marketplace publishes sequentially - Remove skipDuplicate since jobs can now be rerun independently
1 parent 742e831 commit 9e89fac

File tree

1 file changed

+27
-4
lines changed

1 file changed

+27
-4
lines changed

.github/workflows/deploy.yaml

Lines changed: 27 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ on:
77
branches: [main]
88

99
jobs:
10-
publish-extension:
10+
publish-to-open-vsx:
1111
runs-on: ubuntu-latest
1212
if: ${{ github.event.workflow_run.conclusion == 'success' }}
1313
environment: production
@@ -47,14 +47,37 @@ jobs:
4747
with:
4848
pat: ${{ secrets.OPEN_VSX_TOKEN }}
4949
packagePath: packages/cursorless-vscode/dist
50-
skipDuplicate: true
50+
51+
- name: Upload VSIX
52+
uses: actions/upload-artifact@v4
53+
with:
54+
name: vscode-extension
55+
path: ${{ steps.publishToOpenVSX.outputs.vsixPath }}
56+
retention-days: 1
57+
58+
publish-to-vs-marketplace:
59+
runs-on: ubuntu-latest
60+
needs: publish-to-open-vsx
61+
environment: production
62+
63+
steps:
64+
- name: Download VSIX
65+
uses: actions/download-artifact@v4
66+
with:
67+
name: vscode-extension
68+
69+
- name: Get VSIX file path
70+
id: getPath
71+
run: |
72+
VSIX_FILE=$(find . -maxdepth 1 -name "*.vsix" -type f)
73+
echo "vsixPath=$VSIX_FILE" >> $GITHUB_OUTPUT
5174
5275
- name: Publish to Visual Studio Marketplace
5376
uses: HaaLeo/publish-vscode-extension@v2
5477
with:
5578
pat: ${{ secrets.VS_MARKETPLACE_TOKEN }}
5679
registryUrl: https://marketplace.visualstudio.com
57-
extensionFile: ${{ steps.publishToOpenVSX.outputs.vsixPath }}
80+
extensionFile: ${{ steps.getPath.outputs.vsixPath }}
5881

5982
publish-neovim-extension:
6083
runs-on: ubuntu-latest
@@ -116,7 +139,7 @@ jobs:
116139
push-cursorless-talon:
117140
name: Push cursorless-talon subrepo
118141
runs-on: ubuntu-latest
119-
needs: publish-extension
142+
needs: [publish-to-vs-marketplace, publish-neovim-extension]
120143
environment: production
121144

122145
steps:

0 commit comments

Comments
 (0)