Experimental Python Support #34
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Package Extension | |
on: | |
pull_request: | |
push: | |
branches: main | |
tags-ignore: | |
- "**" | |
release: | |
types: | |
- created | |
jobs: | |
test-and-package: | |
name: "Test & Package" | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: oven-sh/setup-bun@v2 | |
- run: bun install | |
- name: Lint & Check Formatting | |
run: | | |
failure=0 | |
bun prettier . --check || failure=1 | |
bun eslint || failure=1 | |
- name: Test | |
run: bun test | |
- run: bun run package | |
- name: Setup Environment | |
run: node -e "console.log('PACKAGE_VERSION=' + require('./package.json').version + '\nPACKAGE_NAME=' + require('./package.json').name + '-' + require('./package.json').version)" >> $GITHUB_ENV | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ env.PACKAGE_NAME }}.vsix | |
path: ./${{ env.PACKAGE_NAME }}.vsix | |
- name: Publish | |
if: success() && startsWith(github.ref, 'refs/tags/v') | |
run: bun vsce-publish | |
env: | |
VSCE_PAT: ${{ secrets.VSCE_PAT }} |