Skip to content

Commit

Permalink
Some changes for flake8
Browse files Browse the repository at this point in the history
  • Loading branch information
fasouto committed Oct 25, 2016
1 parent 3e6ee3f commit 4713da7
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
16 changes: 8 additions & 8 deletions project_name/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import os

## PATHS
# PATHS
# Path containing the django project
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
path.append(BASE_DIR)
Expand All @@ -22,7 +22,7 @@
path.append(os.path.join(PROJECT_ROOT, "libs"))


## SITE SETTINGS
# SITE SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#site-id
SITE_ID = 1

Expand Down Expand Up @@ -64,14 +64,14 @@
'django.contrib.auth.hashers.CryptPasswordHasher',
)

## DEBUG SETTINGS
# DEBUG SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#debug
DEBUG = False

# https://docs.djangoproject.com/en/1.10/ref/settings/#internal-ips
INTERNAL_IPS = ('127.0.0.1')

## LOCALE SETTINGS
# LOCALE SETTINGS
# Local time zone for this installation.
# https://docs.djangoproject.com/en/1.10/ref/settings/#time-zone
TIME_ZONE = 'America/Los_Angeles'
Expand All @@ -89,7 +89,7 @@
USE_TZ = True


## MEDIA AND STATIC SETTINGS
# MEDIA AND STATIC SETTINGS
# Absolute filesystem path to the directory that will hold user-uploaded files.
# https://docs.djangoproject.com/en/1.10/ref/settings/#media-root
MEDIA_ROOT = os.path.join(PROJECT_ROOT, 'public/media')
Expand Down Expand Up @@ -120,7 +120,7 @@
'django.contrib.staticfiles.finders.AppDirectoriesFinder',
)

## TEMPLATE SETTINGS
# TEMPLATE SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#templates
TEMPLATES = [
{
Expand All @@ -140,12 +140,12 @@
]


## URL SETTINGS
# URL SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#root-urlconf.
ROOT_URLCONF = '{{ project_name }}.urls'


## MIDDLEWARE SETTINGS
# MIDDLEWARE SETTINGS
# See: https://docs.djangoproject.com/en/1.10/ref/settings/#middleware-classes
MIDDLEWARE_CLASSES = [
'django.middleware.security.SecurityMiddleware',
Expand Down
8 changes: 4 additions & 4 deletions project_name/settings/development.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
from .base import *
from .base import * # noqa

DEBUG = True

INTERNAL_IPS = ["127.0.0.1"]

SECRET_KEY = "secret"

## DATABASE SETTINGS
# DATABASE SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#databases
DATABASES = {
'default': {
Expand All @@ -28,7 +28,7 @@
EMAIL_BACKEND = "django.core.mail.backends.console.EmailBackend"


## DJANGO DEBUG TOOLBAR SETTINGS
# DJANGO DEBUG TOOLBAR SETTINGS
# https://django-debug-toolbar.readthedocs.org
def show_toolbar(request):
return not request.is_ajax() and request.user and request.user.is_superuser
Expand Down Expand Up @@ -61,6 +61,6 @@ def show_toolbar(request):
)

try:
from local_settings import *
from local_settings import * # noqa
except ImportError:
pass
12 changes: 6 additions & 6 deletions project_name/settings/production.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import os
from .base import *
from .base import * # noqa

DEBUG = False

## DATABASE SETTINGS
# DATABASE SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#databases
DATABASES = {
'default': {
Expand All @@ -23,19 +23,19 @@
# https://docs.djangoproject.com/en/1.10/howto/deployment/checklist/#secret-key
SECRET_KEY = os.environ['SECRET_KEY']

## WSGI SETTINGS
# WSGI SETTINGS
# https://docs.djangoproject.com/en/1.10/ref/settings/#wsgi-application
WSGI_APPLICATION = '{{ project_name }}.wsgi.application'

## NOTIFICATIONS
# NOTIFICATIONS
# A tuple that lists people who get code error notifications.
# https://docs.djangoproject.com/en/1.10/ref/settings/#admins
ADMINS = (
('Your Name', 'your_email@example.com'),
)
MANAGERS = ADMINS

## DJANGO-COMPRESSOR SETTINGS
# DJANGO-COMPRESSOR SETTINGS
COMPRESS_PRECOMPILERS = (
('text/less', 'lessc {infile} {outfile}'),
)
Expand All @@ -44,6 +44,6 @@
)

try:
from local_settings import *
from local_settings import * # noqa
except ImportError:
pass

0 comments on commit 4713da7

Please sign in to comment.