Skip to content

Commit 3e47fd4

Browse files
committed
[Fixes GeoNode#5719] Add pre-commit and black
1 parent f60ff13 commit 3e47fd4

File tree

3 files changed

+31
-1
lines changed

3 files changed

+31
-1
lines changed

.pre-commit-config.yaml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# See https://pre-commit.com for more information
2+
# See https://pre-commit.com/hooks.html for more hooks
3+
repos:
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v2.5.0
6+
hooks:
7+
- id: trailing-whitespace
8+
- id: end-of-file-fixer
9+
- id: check-yaml
10+
- id: check-added-large-files
11+
- repo: https://github.com/psf/black
12+
rev: 19.10b0
13+
hooks:
14+
- id: black

pyproject.toml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[tool.black]
2+
line-length = 120
3+
target-version = 'py35'
4+
exclude = '''
5+
/(
6+
geonode/.*/migrations/.*
7+
| geonode/.*/settings.py
8+
| management
9+
| scripts
10+
| docs
11+
| static
12+
| migrations
13+
| node_modules
14+
)/
15+
'''

requirements_dev.txt

+2-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
ipdb
1+
ipdb
2+
pre-commit

0 commit comments

Comments
 (0)