File tree Expand file tree Collapse file tree 1 file changed +24
-7
lines changed
Expand file tree Collapse file tree 1 file changed +24
-7
lines changed Original file line number Diff line number Diff line change 3030 - name : Package the extension
3131 run : npm run package
3232
33+ - name : Upload VSIX artifact
34+ uses : actions/upload-artifact@v4
35+ with :
36+ name : vscode-extension
37+ path : " *.vsix"
38+
3339 deploy :
3440 runs-on : ubuntu-latest
3541 needs : build
@@ -38,16 +44,27 @@ jobs:
3844 steps :
3945 - name : Checkout code
4046 uses : actions/checkout@v4
41-
42- - name : Upload VSIX file
43- uses : actions/upload -artifact@v4
47+
48+ - name : Download VSIX artifact
49+ uses : actions/download -artifact@v4
4450 with :
4551 name : vscode-extension
46- path : ' **/*.vsix'
52+
53+ - name : Set up Node.js
54+ uses : actions/setup-node@v4
55+ with :
56+ node-version : ' 20'
4757
4858 - name : Deploy to Marketplace
4959 run : |
5060 echo "Deploying to the marketplace..."
51- # Add your deployment script or command here
52- # For example, using vsce to publish the extension
53- npx vsce publish --pat ${{ secrets.VSCE_PAT }}
61+ # Publish pre-built VSIX using the maintained @vscode/vsce package
62+ FILE=$(ls -1 *.vsix | head -n 1)
63+ echo "Publishing $FILE"
64+ if [ -z "${VSCE_PAT}" ]; then
65+ echo "VSCE_PAT secret is not set" >&2
66+ exit 1
67+ fi
68+ npx @vscode/vsce publish --pat "${VSCE_PAT}" --packagePath "$FILE"
69+ env :
70+ VSCE_PAT : ${{ secrets.VSCE_PAT }}
You can’t perform that action at this time.
0 commit comments