django-orchestra/orchestra/management/commands/staticcheck.py
2015-04-05 10:46:24 +00:00

13 lines
403 B
Python

from django.core.management.base import BaseCommand
from orchestra.utils.paths import get_orchestra_dir, get_site_dir
from orchestra.utils.sys import run
class Command(BaseCommand):
help = "Run flake8 syntax checks."
def handle(self, *filenames, **options):
flake = run('flake8 {%s,%s} | grep -v "W293\|E501"' % (get_orchestra_dir(), get_site_dir()))
print(flake.stdout)