You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
968 B
44 lines
968 B
name: Lint
|
|
|
|
on:
|
|
push:
|
|
pull_request:
|
|
types: [ opened, synchronize ]
|
|
|
|
jobs:
|
|
check:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
with:
|
|
fetch-depth: 0
|
|
|
|
- name: Set up CPython 3.8
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: '3.8'
|
|
|
|
- name: Install dependencies
|
|
id: install-deps
|
|
run: |
|
|
python -m pip install --upgrade pip setuptools wheel black==22.6
|
|
pip install -U -r requirements.txt
|
|
|
|
- name: Set up node.js
|
|
uses: actions/setup-node@v2
|
|
with:
|
|
node-version: '16'
|
|
|
|
- name: Install pyright
|
|
run: |
|
|
npm install -g pyright@1.1.235
|
|
|
|
- name: Run pyright
|
|
run: |
|
|
pyright
|
|
|
|
- name: Run black
|
|
if: ${{ always() && steps.install-deps.outcome == 'success' }}
|
|
run: |
|
|
black --check --verbose discord examples
|
|
|