diff --git a/.github/workflows/ci-dev.yaml b/.github/workflows/ci-dev.yaml new file mode 100644 index 0000000..97e9948 --- /dev/null +++ b/.github/workflows/ci-dev.yaml @@ -0,0 +1,31 @@ +name: CI +on: + pull_request: + branches: ["main"] + push: + branches: ["main"] + +jobs: + ci: + uses: qiime2/distributions/.github/workflows/lib-ci-dev.yaml@dev + with: + distro: shotgun + additional-reports-path: ./coverage.xml + additional-reports-name: coverage + + coverage: + needs: [ci] + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: actions/download-artifact@v3 + name: 'Fetch coverage from builds' + with: + name: ${{ needs.ci.outputs.additional-reports-name }} + path: ${{ needs.ci.outputs.additional-reports-path }} + + - uses: codecov/codecov-action@v3 + name: 'Upload coverage' + with: + fail_ci_if_error: true diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index ab375b3..0000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,61 +0,0 @@ -name: Test and build - -on: - pull_request: - branches: - - main - push: - -jobs: - lint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - - name: set up python 3.8 - uses: actions/setup-python@v1 - with: - python-version: 3.8 - - - name: install dependencies - run: pip install -q flake8 - - - name: lint - run: flake8 - - rust-test: - runs-on: macos-latest - steps: - - uses: actions/checkout@v2 - - uses: actions-rs/toolchain@v1 - with: - toolchain: stable - - run: cargo test - working-directory: ./fastq_writer - - build-and-test: - needs: [lint, rust-test] - strategy: - matrix: - os: [ubuntu-latest, macos-latest] - runs-on: ${{ matrix.os }} - steps: - - uses: actions/checkout@v2 - with: - # necessary for versioneer - fetch-depth: 0 - - - name: Hack - template coverage output path - run: echo "COV=coverage xml -o $GITHUB_WORKSPACE/coverage.xml" >> $GITHUB_ENV - - - uses: qiime2/action-library-packaging@alpha1 - with: - package-name: q2-fondue - additional-tests: ${{ env.COV }} - build-target: dev - library-token: ${{ secrets.LIBRARY_TOKEN }} - - - name: Upload coverage to Codecov - uses: codecov/codecov-action@v2 - with: - fail_ci_if_error: true diff --git a/.github/workflows/join-release.yaml b/.github/workflows/join-release.yaml new file mode 100644 index 0000000..298bce4 --- /dev/null +++ b/.github/workflows/join-release.yaml @@ -0,0 +1,6 @@ +name: join-release +on: + workflow_dispatch: {} +jobs: + release: + uses: qiime2/distributions/.github/workflows/lib-join-release.yaml@dev diff --git a/.github/workflows/tag-release.yaml b/.github/workflows/tag-release.yaml new file mode 100644 index 0000000..fdbcab3 --- /dev/null +++ b/.github/workflows/tag-release.yaml @@ -0,0 +1,7 @@ +name: tag-release +on: + push: + branches: ["Release-*"] +jobs: + tag: + uses: qiime2/distributions/.github/workflows/lib-tag-release.yaml@dev diff --git a/README.md b/README.md index b80a4a7..7740fd6 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # q2-fondue -![CI](https://github.com/bokulich-lab/q2-fondue/actions/workflows/ci.yml/badge.svg) +![CI](https://github.com/bokulich-lab/q2-fondue/actions/workflows/ci-dev.yaml/badge.svg) [![codecov](https://codecov.io/gh/bokulich-lab/q2-fondue/branch/main/graph/badge.svg?token=UTM4W4B1KW)](https://codecov.io/gh/bokulich-lab/q2-fondue) [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.6388476.svg)](https://doi.org/10.5281/zenodo.6388476) [![DOI](http://img.shields.io/badge/DOI-10.1093/bioinformatics/btac639-B31B1B.svg)](https://doi.org/10.1093/bioinformatics/btac639) diff --git a/ci/recipe/meta.yaml b/ci/recipe/meta.yaml index 4529a06..3c3c259 100644 --- a/ci/recipe/meta.yaml +++ b/ci/recipe/meta.yaml @@ -42,7 +42,7 @@ test: - coverage - pytest-cov commands: - - pytest --cov q2_fondue --pyargs q2_fondue + - pytest --cov q2_fondue --cov-report xml:coverage.xml --pyargs q2_fondue about: home: https://github.com/bokulich-lab/q2-fondue