Skip to content

Commit 0291e3e

Browse files
committed
Enforce Black, closes #119
1 parent 5e3f308 commit 0291e3e

4 files changed

Lines changed: 10 additions & 5 deletions

File tree

.github/workflows/test.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,6 @@ jobs:
2727
- name: Run tests
2828
run: |
2929
pytest
30+
- name: Check formatting
31+
run: black . --check
3032

django_sql_dashboard/migrations/0004_add_description_help_text.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,15 @@
66
class Migration(migrations.Migration):
77

88
dependencies = [
9-
('django_sql_dashboard', '0003_update_metadata'),
9+
("django_sql_dashboard", "0003_update_metadata"),
1010
]
1111

1212
operations = [
1313
migrations.AlterField(
14-
model_name='dashboard',
15-
name='description',
16-
field=models.TextField(blank=True, help_text='Optional description (Markdown allowed)'),
14+
model_name="dashboard",
15+
name="description",
16+
field=models.TextField(
17+
blank=True, help_text="Optional description (Markdown allowed)"
18+
),
1719
),
1820
]

docs/contributing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ To generate migrations for model changes:
2929

3030
## Code style
3131

32-
This library uses [Black](https://github.com/psf/black) for code formatting.
32+
This library uses [Black](https://github.com/psf/black) for code formatting. The correct version of Black will be installed by `pip install -e '.[test]'` - you can run `black .` in the root directory to apply those formatting rules.
3333

3434
## Documentation
3535

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ def get_long_description():
4040
install_requires=["Django>=3.0", "markdown", "bleach"],
4141
extras_require={
4242
"test": [
43+
"black==21.5b2",
4344
"psycopg2",
4445
"pytest",
4546
"pytest-django==4.2.0",

0 commit comments

Comments
 (0)