Skip to content

Commit

Permalink
Apply Black to entire codebase (#990)
Browse files Browse the repository at this point in the history
* Apply Black to entire codebase
* Add Black GitHub Action
  • Loading branch information
smithdc1 committed Feb 26, 2020
1 parent 7aa1717 commit 6c0ffe2
Show file tree
Hide file tree
Showing 27 changed files with 1,358 additions and 1,664 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/black.yml
@@ -0,0 +1,22 @@
name: black

on: [push, pull_request]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v1
with:
python-version: 3.8
- name: Install Black
run: |
python -m pip install --upgrade pip
pip install Black
- name: run black
run: |
black crispy_forms --check
3 changes: 3 additions & 0 deletions README.rst
Expand Up @@ -6,6 +6,9 @@ django-crispy-forms
:alt: Build Status
:target: https://travis-ci.org/django-crispy-forms/django-crispy-forms

.. image:: https://img.shields.io/badge/code%20style-black-000000.svg
:target: https://github.com/psf/black

.. image:: http://codecov.io/github/django-crispy-forms/django-crispy-forms/coverage.svg?branch=master
:target: http://codecov.io/github/django-crispy-forms/django-crispy-forms?branch=master

Expand Down
2 changes: 1 addition & 1 deletion crispy_forms/__init__.py
@@ -1 +1 @@
__version__ = '1.8.1'
__version__ = "1.8.1"
1 change: 1 addition & 0 deletions crispy_forms/base.py
Expand Up @@ -8,6 +8,7 @@ class KeepContext:
Layout objects should use `extra_context` to introduce context variables, never
touch context object themselves, that could introduce side effects.
"""

def __init__(self, context, keys):
self.context = context
self.keys = keys
Expand Down

0 comments on commit 6c0ffe2

Please sign in to comment.