diff --git a/.github/workflows/update_hosts.yml b/.github/workflows/update_hosts.yml index 75f398e..9ac2b2d 100644 --- a/.github/workflows/update_hosts.yml +++ b/.github/workflows/update_hosts.yml @@ -40,10 +40,15 @@ jobs: python -m pip install --upgrade pip sudo pip install -r requirements.txt - - name: 'Run PEP8' - uses: quentinguidee/pep8-action@v1 - with: - arguments: '--max-line-length=120' + - name: Install pycodestyle + run: pip install pycodestyle + - name: Run pycodestyle + id: pycodestyle + run: | + git diff --name-only ${{ github.event.before }} ${{ github.sha }} | grep '\.py$' | xargs pycodestyle --statistics > pep8_issues.txt || true + - name: Read pycodestyle output + id: read_pep8_issues + run: echo "::set-output name=pep8_issues::$(cat pep8_issues.txt)" - name: Run hosts update script1 run: |