Skip to content

Commit f8c16fe

Browse files
committed
Added pre-commit checks.
1 parent eb55489 commit f8c16fe

File tree

3 files changed

+18
-0
lines changed

3 files changed

+18
-0
lines changed

.devcontainer/post_create.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ sudo apt install -y libgdal-dev gdal-bin
55
pip install --upgrade pip
66
pip install --user -r requirements.txt
77
git config --local include.path ../.gitconfig
8+
pre-commit install

.pre-commit-config.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
repos:
2+
- repo: https://github.com/psf/black
3+
rev: 23.1.0
4+
hooks:
5+
- id: black
6+
- id: black-jupyter
7+
- repo: https://github.com/nbQA-dev/nbQA
8+
rev: 1.6.3
9+
hooks:
10+
- id: nbqa-ruff
11+
additional_dependencies: [ruff==0.0.256]
12+
- repo: https://github.com/charliermarsh/ruff-pre-commit
13+
rev: v0.0.256
14+
hooks:
15+
- id: ruff
16+
args: [--exit-non-zero-on-fix]

requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ nbformat==5.7.3
88
pandas==1.5.3
99
pandas-datareader==0.10.0
1010
plotly==5.13.1
11+
pre-commit==3.2.0
1112
pyarrow==11.0.0
1213
pynytimes==0.9.0
1314
textblob==0.17.1

0 commit comments

Comments
 (0)