chore: .pyc should never be checked-in #42
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
# This is a workflow to format Python code with black formatter | |
name: coding style | |
# Declare default permissions as read only. | |
permissions: read-all | |
# Controls when the action will run. Triggers the workflow on push or pull request | |
# events but only for the master branch | |
on: | |
pull_request: | |
push: | |
branches: [main] | |
# A workflow run is made up of one or more jobs that can run sequentially or in parallel | |
jobs: | |
# The isort job sorts all imports in .py, .pyx, .pxd files | |
isort: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- uses: jamescurtin/isort-action@master | |
with: | |
configuration: "--check-only --profile black --filter-files -sl" | |
black: | |
# The type of runner that the job will run on | |
runs-on: ubuntu-latest | |
# Steps represent a sequence of tasks that will be executed as part of the job | |
steps: | |
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it | |
- uses: actions/checkout@v3 | |
# Set up a Python environment for use in actions | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
# Run black code formatter | |
- uses: psf/black@stable | |
with: | |
src: "." | |
options: "--check" | |
version: "22.12.0" | |
flake8: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install flake8 | |
- name: Lint with flake8 | |
uses: py-actions/flake8@v2 |