Add functionality for setting custom names #613
Workflow file for this run
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: ReSDK CI | |
on: | |
push: | |
branches: | |
- master | |
tags: | |
- "[0-9]+.[0-9]+.[0-9]+*" | |
pull_request: | |
workflow_dispatch: | |
jobs: | |
unittest: | |
runs-on: arc-runner | |
env: | |
TOX_COMMAND: "tox --skip-missing-interpreters false" | |
strategy: | |
fail-fast: false | |
matrix: | |
toxenv: [py38, py39, py310, py311, py312, docs, linters, package] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Assert PR is up-to-date | |
if: github.event_name == 'pull_request' | |
run: | | |
git fetch origin ${{ github.base_ref }} | |
git fetch origin HEAD --unshallow | |
git_change_target_merge_base=$(git merge-base HEAD origin/${{ github.base_ref }}) | |
git_change_target_sha=$(git rev-parse origin/${{ github.base_ref }}) | |
if [[ "${git_change_target_merge_base}" != "${git_change_target_sha}" ]]; then | |
echo 'Pull request is not up-to-date!' | |
echo "Please, rebase your pull request on top of '${{ github.base_ref }}' (commit: ${git_change_target_sha})." | |
exit 1 | |
fi | |
- name: Run Tests | |
run: > | |
${{ env.TOX_COMMAND }} -e ${{ matrix.toxenv }} | |
e2e: | |
uses: ./.github/workflows/e2e.yaml | |
build: | |
runs-on: arc-runner | |
needs: [unittest, e2e] | |
if: startsWith(github.ref, 'refs/tags') | |
env: | |
PYTHON: "python3.12" | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install build | |
run: ${{ env.PYTHON }} -m pip install --user build | |
- name: Build a binary wheel and a source tarball | |
run: ${{ env.PYTHON }} -m build --sdist --wheel --outdir dist/ . | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v1 | |
with: | |
file: .coverage | |
- name: Publish distribution to PyPI | |
uses: pypa/gh-action-pypi-publish@release/v1.8 | |
with: | |
password: ${{ secrets.pypi_password }} |