diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2c3bfbe8..b43b46e3 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -30,8 +30,16 @@ jobs: - uses: actions/setup-python@v2 with: python-version: ${{ matrix.python }} - - run: pip install -U tox + - name: install + shell: bash + run: | + pip install -U tox + mkdir -p "$HOME/bin" + curl -sfL https://coverage.codacy.com/get.sh > "$HOME/bin/codacy" + chmod +x "$HOME/bin/codacy" + echo "$HOME/bin" >> $GITHUB_PATH - run: tox -e py${PYVER/./} + shell: bash env: PYVER: ${{ matrix.python }} CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} @@ -49,7 +57,13 @@ jobs: - uses: actions/setup-python@v2 with: python-version: ${{ matrix.python }} - - run: pip install -U tox + - name: install + run: | + pip install -U tox + mkdir -p "$HOME/bin" + curl -sfL https://coverage.codacy.com/get.sh > "$HOME/bin/codacy" + chmod +x "$HOME/bin/codacy" + echo "$HOME/bin" >> $GITHUB_PATH - name: tox run: | if [[ "$PYVER" == py* ]]; then @@ -104,7 +118,6 @@ jobs: skip_existing: true - id: collect_assets name: Collect assets - shell: bash run: | echo "::set-output name=asset_path::$(ls dist/*.whl)" echo "::set-output name=asset_name::$(basename dist/*.whl)" @@ -154,7 +167,6 @@ jobs: with: use_lxd: true - name: Snap build - shell: bash run: | export SNAPCRAFT_IMAGE_INFO='{"build_url": "https://github.com/tqdm/tqdm/actions/runs/'$GITHUB_RUN_ID'"}' sg lxd -c 'snapcraft --use-lxd' @@ -168,7 +180,6 @@ jobs: snapcraft_token: ${{ secrets.SNAP_TOKEN }} - if: github.event_name == 'push' && steps.collect_assets.outputs.snap_channel name: Snap deploy - shell: bash run: | if [ -n "$(ls tqdm*.snap 2>/dev/null)" ]; then sudo snapcraft upload tqdm*.snap --release $CHANNEL diff --git a/tox.ini b/tox.ini index 01cfb957..f65c1ee7 100644 --- a/tox.ini +++ b/tox.ini @@ -17,11 +17,8 @@ deps = commands = pytest --cov=tqdm --cov-report=xml --cov-report=term -k "not tests_perf" - coveralls - - curl -OL https://coverage.codacy.com/get.sh - - bash get.sh report -r coverage.xml -allowlist_externals = - curl - bash + - codacy report -r coverage.xml +allowlist_externals = codacy [extra] deps = @@ -31,8 +28,7 @@ commands = pytest --durations=10 --cov=tqdm --cov-report=xml --cov-report=term -k "not tests_perf" - coveralls codecov - - curl -OL https://coverage.codacy.com/get.sh - - bash get.sh report -r coverage.xml + - codacy report -r coverage.xml allowlist_externals = {[coverage]allowlist_externals} [testenv] @@ -65,8 +61,7 @@ commands = pytest --durations=0 -k tests_perf [testenv:flake8] deps = flake8 -commands = - flake8 -j 8 --count --statistics . +commands = flake8 -j 8 --count --statistics . [testenv:setup.py] deps =