Skip to content

Commit 16a3890

Browse files
committed
Updated config
1 parent dc5dafb commit 16a3890

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

config/settings.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
"""
1212

1313
import os
14+
from pathlib import Path
1415

1516
import dj_database_url
1617

@@ -23,8 +24,8 @@
2324
EMPTY_VALUE_DISPLAY = ''
2425
# ---------------------------------------
2526

26-
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
27-
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
27+
# Build paths inside the project like this: BASE_DIR / 'subdir'.
28+
BASE_DIR = Path(__file__).resolve().parent.parent
2829

2930

3031
# Quick-start development settings - unsuitable for production
@@ -46,6 +47,7 @@
4647
'app',
4748
'tv_series.apps.TvSeriesConfig',
4849
'books.apps.BooksConfig',
50+
'backup',
4951

5052
# Dependencies
5153
'django.contrib.admin',
@@ -134,7 +136,7 @@
134136
# https://docs.djangoproject.com/en/2.2/howto/static-files/
135137

136138
STATIC_URL = '/static/'
137-
STATIC_ROOT = os.path.join(BASE_DIR, 'static')
139+
STATIC_ROOT = BASE_DIR / 'static'
138140

139141
AUTH_USER_MODEL = 'app.User'
140142

data/celerybeat-schedule/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/data.db

0 commit comments

Comments
 (0)