From faee02cd1435ba167a8ed6eeb67879cd22c8d019 Mon Sep 17 00:00:00 2001 From: dherrada Date: Mon, 27 Jul 2020 10:08:17 -0400 Subject: [PATCH 1/2] Testing check for setup.py --- .github/workflows/build.yml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 5abe58d..17b6e2f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,3 +1,7 @@ +# SPDX-FileCopyrightText: 2017 Scott Shawcroft, written for Adafruit Industries +# +# SPDX-License-Identifier: MIT + name: Build CI on: [pull_request, push] @@ -38,14 +42,14 @@ jobs: # (e.g. - apt-get: gettext, etc; pip: circuitpython-build-tools, requirements.txt; etc.) run: | source actions-ci/install.sh - - name: Pip install pylint, black, & Sphinx + - name: Pip install pylint, Sphinx, pre-commit run: | - pip install --force-reinstall pylint black==19.10b0 Sphinx sphinx-rtd-theme + pip install --force-reinstall pylint Sphinx sphinx-rtd-theme pre-commit - name: Library version run: git describe --dirty --always --tags - - name: Check formatting + - name: Pre-commit hooks run: | - black --check --target-version=py35 . + pre-commit run --all-files - name: PyLint run: | pylint $( find . -path './adafruit*.py' ) @@ -55,7 +59,12 @@ jobs: - name: Build docs working-directory: docs run: sphinx-build -E -W -b html . _build/html + - name: Check For setup.py + id: need-pypi + run: | + echo ::set-output name=setup-py::$( find . -wholename './setup.py' ) - name: Build Python package + if: contains(steps.need-pypi.outputs.setup-py, 'setup.py') run: | pip install --upgrade setuptools wheel twine readme_renderer testresources python setup.py sdist From 269366c145e4e77b250d6a21c2a9ded79e9facd1 Mon Sep 17 00:00:00 2001 From: dherrada Date: Mon, 27 Jul 2020 10:13:31 -0400 Subject: [PATCH 2/2] Removed pre-commit --- .github/workflows/build.yml | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 17b6e2f..e163727 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,7 +1,3 @@ -# SPDX-FileCopyrightText: 2017 Scott Shawcroft, written for Adafruit Industries -# -# SPDX-License-Identifier: MIT - name: Build CI on: [pull_request, push] @@ -42,14 +38,14 @@ jobs: # (e.g. - apt-get: gettext, etc; pip: circuitpython-build-tools, requirements.txt; etc.) run: | source actions-ci/install.sh - - name: Pip install pylint, Sphinx, pre-commit + - name: Pip install pylint, black, & Sphinx run: | - pip install --force-reinstall pylint Sphinx sphinx-rtd-theme pre-commit + pip install --force-reinstall pylint black==19.10b0 Sphinx sphinx-rtd-theme - name: Library version run: git describe --dirty --always --tags - - name: Pre-commit hooks + - name: Check formatting run: | - pre-commit run --all-files + black --check --target-version=py35 . - name: PyLint run: | pylint $( find . -path './adafruit*.py' )