Skip to content

Deno Integration

Deno Integration #140

Workflow file for this run

name: build-pr
on:
pull_request:
types: [opened, synchronize, reopened, closed]
branches: ['master']
env:
VERSION: 'undefined'
TOKEN: ${{secrets.PAT}}
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: 'pip'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Run tests with coverage
run: pytest --tb=short -q --cov=. --cov-report=html
- name: Upload coverage report
uses: actions/upload-artifact@v4
if: always()
with:
name: coverage-report
path: htmlcov/
# for PRs the versioning does not append the SHA to indicate a prerelease, we do this manually in the build-* call below
versioning:
needs: test
runs-on: ubuntu-latest
outputs:
VERSION: ${{ steps.tag_version.outputs.new_version }}
steps:
- uses: actions/checkout@v4
- name: Bump version and push tag
id: tag_version
uses: mathieudutour/github-tag-action@v6.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
release_branches: 'master'
dry_run: true
build:
needs: versioning
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Build addon
run: $GITHUB_WORKSPACE/.github/scripts/build-addon.sh ${{ needs.versioning.outputs.VERSION }}.$GITHUB_SHA
- name: Upload Addon-artifacts
uses: actions/upload-artifact@v4
with:
name: Addon-artifacts
path: "${{ runner.temp }}/*.zip"