From 48e3ebb4a1c2894f74a9da5865d4a5155d81877b Mon Sep 17 00:00:00 2001 From: Arthurvroum Date: Thu, 9 Apr 2026 10:33:57 +0200 Subject: [PATCH] ci: automate vs code extension deployment on tags --- .github/workflows/publish.yml | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/publish.yml diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..2ad102a --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,33 @@ +name: Publish to VS Code Marketplace + +on: + push: + tags: + - 'v*' # Se déclenche uniquement quand on pousse un tag, ex: git tag v0.1.1 && git push origin v0.1.1 + +jobs: + publish: + name: Publish Extension + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: 18.x + cache: 'npm' + + - name: Install dependencies + run: npm ci + + - name: Run Tests + run: xvfb-run -a npm test + + - name: Publish Pre-release (Beta) + uses: liximomo/vsceaction@v1 + with: + args: publish --pre-release + env: + VSCE_PAT: ${{ secrets.VSCE_PAT }}