Skip to content
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

Pre commit Hooks (black, flake8, mypy, etc) [CT-105] #4639

Merged
merged 34 commits into from
Feb 11, 2022
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
fb9cca1
testing pre-commit hook
iknox-fa Jan 27, 2022
e9ac78e
test pre-commit 2
iknox-fa Jan 27, 2022
3f48ea4
adding pre-commit hook
iknox-fa Jan 27, 2022
45db18b
return setup.py
iknox-fa Jan 27, 2022
9fafac6
return setup.py again
iknox-fa Jan 27, 2022
75201be
PR feedback
iknox-fa Feb 1, 2022
a7d99a9
PR feedback
iknox-fa Feb 1, 2022
4d44780
adjust tox settings for flake8 to match black
iknox-fa Feb 3, 2022
675d551
adding flake8 to hooks
iknox-fa Feb 4, 2022
35a6447
updates.. moar
iknox-fa Feb 4, 2022
d3865d7
Makefile changes
iknox-fa Feb 4, 2022
3d65519
Makefile Makeove! Squeee
iknox-fa Feb 4, 2022
181dd12
fixed gitignore bug + tidying
iknox-fa Feb 4, 2022
e66aa6a
removed tox lint targets
iknox-fa Feb 4, 2022
f11b323
merge main
iknox-fa Feb 4, 2022
bce4bb1
Regexes.. Ugh
iknox-fa Feb 4, 2022
c29e7ee
nope
iknox-fa Feb 4, 2022
7e1af5d
swapped pre-commit in for tox on code checks
iknox-fa Feb 4, 2022
8d900e9
fixups for mypy and test exclusion
iknox-fa Feb 8, 2022
4f35cbf
PR feedback
iknox-fa Feb 8, 2022
cb09add
PR feedback
iknox-fa Feb 8, 2022
64eede8
PR feedback
iknox-fa Feb 8, 2022
b7a6d01
PR feedback
iknox-fa Feb 8, 2022
522b4f7
PR feedback
iknox-fa Feb 8, 2022
7c13388
PR feedback
iknox-fa Feb 8, 2022
a18c790
PR Feedback
iknox-fa Feb 8, 2022
8477fdb
PR feedback
iknox-fa Feb 8, 2022
33727ed
updated makefile, added pre-commit targets
iknox-fa Feb 9, 2022
2161a53
updated stages for checks
iknox-fa Feb 10, 2022
8af83a0
PR feedback
iknox-fa Feb 10, 2022
2df7667
removed black from make lint (too slow)
iknox-fa Feb 11, 2022
e5cf9fa
merge master
iknox-fa Feb 11, 2022
e2f7f5a
updating workflow to install mypy
iknox-fa Feb 11, 2022
e64cc0a
updating workflow to install editable reqs
iknox-fa Feb 11, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
repos:
iknox-fa marked this conversation as resolved.
Show resolved Hide resolved
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: check-yaml
- id: check-json
- id: end-of-file-fixer
- id: trailing-whitespace
- id: check-case-conflict
- repo: https://github.com/psf/black
rev: 21.12b0
hooks:
- id: black
language_version: python3
args: [--line-length=99]
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ endif
.PHONY: dev
dev: ## Installs dbt-* packages in develop mode along with development dependencies.
pip install -r dev-requirements.txt -r editable-requirements.txt
pre-commit install

.PHONY: mypy
mypy: .env ## Runs mypy for static type checking.
Expand Down Expand Up @@ -85,4 +86,3 @@ help: ## Show this help message.
@echo
@echo 'options:'
@echo 'use USE_DOCKER=true to run target in a docker container'

1 change: 1 addition & 0 deletions dev-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ freezegun==0.3.12
ipdb
mypy==0.782
pip-tools
pre-commit
pytest
pytest-dotenv
pytest-logbook
Expand Down