donors

git clone git://ce9e.org/donors

commit
a8e74628ad5e6da69a096b641120241bd2d644c9
Author
Tobias Bengfort <tobias.bengfort@posteo.de>
Date
2021-03-06 11:52
startproject

Diffstat

A donors/__init__.py 0
A donors/settings.py 120 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
A donors/urls.py 6 ++++++
A donors/wsgi.py 3 +++
A manage.py 22 ++++++++++++++++++++++

5 files changed, 151 insertions, 0 deletions


diff --git a/donors/__init__.py b/donors/__init__.py

diff --git a/donors/settings.py b/donors/settings.py

@@ -0,0 +1,120 @@
   -1     1 """
   -1     2 Django settings for donors project.
   -1     3 
   -1     4 Generated by 'django-admin startproject' using Django 3.1.7.
   -1     5 
   -1     6 For more information on this file, see
   -1     7 https://docs.djangoproject.com/en/3.1/topics/settings/
   -1     8 
   -1     9 For the full list of settings and their values, see
   -1    10 https://docs.djangoproject.com/en/3.1/ref/settings/
   -1    11 """
   -1    12 
   -1    13 from pathlib import Path
   -1    14 
   -1    15 # Build paths inside the project like this: BASE_DIR / 'subdir'.
   -1    16 BASE_DIR = Path(__file__).resolve().parent.parent
   -1    17 
   -1    18 
   -1    19 # Quick-start development settings - unsuitable for production
   -1    20 # See https://docs.djangoproject.com/en/3.1/howto/deployment/checklist/
   -1    21 
   -1    22 # SECURITY WARNING: keep the secret key used in production secret!
   -1    23 SECRET_KEY = '(_26c1i#kl^vshc6cue$jbq(@_q^m61_0ar^578c=0k)mngcqz'
   -1    24 
   -1    25 # SECURITY WARNING: don't run with debug turned on in production!
   -1    26 DEBUG = True
   -1    27 
   -1    28 ALLOWED_HOSTS = []
   -1    29 
   -1    30 
   -1    31 # Application definition
   -1    32 
   -1    33 INSTALLED_APPS = [
   -1    34     'django.contrib.admin',
   -1    35     'django.contrib.auth',
   -1    36     'django.contrib.contenttypes',
   -1    37     'django.contrib.sessions',
   -1    38     'django.contrib.messages',
   -1    39     'django.contrib.staticfiles',
   -1    40 ]
   -1    41 
   -1    42 MIDDLEWARE = [
   -1    43     'django.middleware.security.SecurityMiddleware',
   -1    44     'django.contrib.sessions.middleware.SessionMiddleware',
   -1    45     'django.middleware.common.CommonMiddleware',
   -1    46     'django.middleware.csrf.CsrfViewMiddleware',
   -1    47     'django.contrib.auth.middleware.AuthenticationMiddleware',
   -1    48     'django.contrib.messages.middleware.MessageMiddleware',
   -1    49     'django.middleware.clickjacking.XFrameOptionsMiddleware',
   -1    50 ]
   -1    51 
   -1    52 ROOT_URLCONF = 'donors.urls'
   -1    53 
   -1    54 TEMPLATES = [
   -1    55     {
   -1    56         'BACKEND': 'django.template.backends.django.DjangoTemplates',
   -1    57         'DIRS': [],
   -1    58         'APP_DIRS': True,
   -1    59         'OPTIONS': {
   -1    60             'context_processors': [
   -1    61                 'django.template.context_processors.debug',
   -1    62                 'django.template.context_processors.request',
   -1    63                 'django.contrib.auth.context_processors.auth',
   -1    64                 'django.contrib.messages.context_processors.messages',
   -1    65             ],
   -1    66         },
   -1    67     },
   -1    68 ]
   -1    69 
   -1    70 WSGI_APPLICATION = 'donors.wsgi.application'
   -1    71 
   -1    72 
   -1    73 # Database
   -1    74 # https://docs.djangoproject.com/en/3.1/ref/settings/#databases
   -1    75 
   -1    76 DATABASES = {
   -1    77     'default': {
   -1    78         'ENGINE': 'django.db.backends.sqlite3',
   -1    79         'NAME': BASE_DIR / 'db.sqlite3',
   -1    80     }
   -1    81 }
   -1    82 
   -1    83 
   -1    84 # Password validation
   -1    85 # https://docs.djangoproject.com/en/3.1/ref/settings/#auth-password-validators
   -1    86 
   -1    87 AUTH_PASSWORD_VALIDATORS = [
   -1    88     {
   -1    89         'NAME': 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator',
   -1    90     },
   -1    91     {
   -1    92         'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator',
   -1    93     },
   -1    94     {
   -1    95         'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator',
   -1    96     },
   -1    97     {
   -1    98         'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator',
   -1    99     },
   -1   100 ]
   -1   101 
   -1   102 
   -1   103 # Internationalization
   -1   104 # https://docs.djangoproject.com/en/3.1/topics/i18n/
   -1   105 
   -1   106 LANGUAGE_CODE = 'en-us'
   -1   107 
   -1   108 TIME_ZONE = 'UTC'
   -1   109 
   -1   110 USE_I18N = True
   -1   111 
   -1   112 USE_L10N = True
   -1   113 
   -1   114 USE_TZ = True
   -1   115 
   -1   116 
   -1   117 # Static files (CSS, JavaScript, Images)
   -1   118 # https://docs.djangoproject.com/en/3.1/howto/static-files/
   -1   119 
   -1   120 STATIC_URL = '/static/'

diff --git a/donors/urls.py b/donors/urls.py

@@ -0,0 +1,6 @@
   -1     1 from django.contrib import admin
   -1     2 from django.urls import path
   -1     3 
   -1     4 urlpatterns = [
   -1     5     path(admin.site.urls),
   -1     6 ]

diff --git a/donors/wsgi.py b/donors/wsgi.py

@@ -0,0 +1,3 @@
   -1     1 from django.core.wsgi import get_wsgi_application
   -1     2 
   -1     3 application = get_wsgi_application()

diff --git a/manage.py b/manage.py

@@ -0,0 +1,22 @@
   -1     1 #!/usr/bin/env python
   -1     2 """Django's command-line utility for administrative tasks."""
   -1     3 import os
   -1     4 import sys
   -1     5 
   -1     6 
   -1     7 def main():
   -1     8     """Run administrative tasks."""
   -1     9     os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'donors.settings')
   -1    10     try:
   -1    11         from django.core.management import execute_from_command_line
   -1    12     except ImportError as exc:
   -1    13         raise ImportError(
   -1    14             "Couldn't import Django. Are you sure it's installed and "
   -1    15             "available on your PYTHONPATH environment variable? Did you "
   -1    16             "forget to activate a virtual environment?"
   -1    17         ) from exc
   -1    18     execute_from_command_line(sys.argv)
   -1    19 
   -1    20 
   -1    21 if __name__ == '__main__':
   -1    22     main()