-
-
Notifications
You must be signed in to change notification settings - Fork 18.6k
CI: add pre-commit action, include pyupgrade #36471
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
8197c61
1a6b477
e8135b4
f4788fa
27e285e
1e5bc80
9c98406
635b8d7
e2a334a
b8aea46
5b6faa1
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
name: pre-commit | ||
|
||
on: | ||
pull_request: | ||
push: | ||
branches: [master] | ||
dsaxton marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
jobs: | ||
pre-commit: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- uses: pre-commit/action@v2.0.0 |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,30 +3,30 @@ repos: | |
rev: 19.10b0 | ||
hooks: | ||
- id: black | ||
language_version: python3 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is already specified here: https://github.com/psf/black/blob/master/.pre-commit-hooks.yaml |
||
- repo: https://gitlab.com/pycqa/flake8 | ||
rev: 3.8.3 | ||
hooks: | ||
- id: flake8 | ||
language: python_venv | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same, they already specify this here https://gitlab.com/pycqa/flake8/-/blob/master/.pre-commit-hooks.yaml and according to pre-commit docs https://pre-commit.com/
|
||
additional_dependencies: [flake8-comprehensions>=3.1.0] | ||
- id: flake8 | ||
name: flake8-pyx | ||
language: python_venv | ||
files: \.(pyx|pxd)$ | ||
types: | ||
- file | ||
args: [--append-config=flake8/cython.cfg] | ||
- id: flake8 | ||
name: flake8-pxd | ||
language: python_venv | ||
files: \.pxi\.in$ | ||
types: | ||
- file | ||
args: [--append-config=flake8/cython-template.cfg] | ||
- repo: https://github.com/pre-commit/mirrors-isort | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this is deprecated, see https://github.com/pre-commit/mirrors-isort
|
||
rev: v5.2.2 | ||
- repo: https://github.com/PyCQA/isort | ||
rev: 5.2.2 | ||
hooks: | ||
- id: isort | ||
language: python_venv | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. already specified in https://github.com/PyCQA/isort/blob/develop/.pre-commit-hooks.yaml |
||
exclude: ^pandas/__init__\.py$|^pandas/core/api\.py$ | ||
- repo: https://github.com/asottile/pyupgrade | ||
rev: v2.7.2 | ||
hooks: | ||
- id: pyupgrade | ||
args: [--py37-plus] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
#!/usr/bin/env python3 | ||
# -*- encoding:utf-8 -*- | ||
""" | ||
Script to generate contributor and pull request lists | ||
|
||
|
Uh oh!
There was an error while loading. Please reload this page.