1 # This file is part of Wolnelektury, licensed under GNU Affero GPLv3 or later.
2 # Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
5 from .paths import VAR_DIR
7 # Absolute path to the directory that holds media.
8 # Example: "/home/media/media.lawrence.com/"
9 MEDIA_ROOT = path.join(VAR_DIR, 'media/')
10 STATIC_ROOT = path.join(VAR_DIR, 'static/')
11 SEARCH_INDEX = path.join(VAR_DIR, 'search_index/')
13 # URL that handles the media served from MEDIA_ROOT. Make sure to use a
14 # trailing slash if there is a path component (optional in other cases).
15 # Examples: "http://media.lawrence.com", "http://example.com/media/"
17 STATIC_URL = '/static/'
19 IMAGE_DIR = 'book/pictures/'
21 # CSS and JavaScript file groups
29 'output_filename': 'css/compressed/2021.css',
32 # styles both for mobile and for big screen
34 'css/import/gelasio.css',
36 'css/jquery.countdown.css',
37 'jplayer/jplayer.blue.monday.css',
39 'sponsors/css/sponsors.css',
43 'css/ui-lightness/jquery-ui-1.8.16.custom.css',
50 'output_filename': 'css/compressed/main.css',
54 'css/import/gelasio.css',
55 'css/master.book.css',
57 'output_filename': 'css/compressed/book.css',
61 'css/import/gelasio.css',
62 'scss/book_text.scss',
65 'annoy/book_text.scss',
67 'css/master.picture.css',
69 'output_filename': 'css/compressed/book_text.css',
75 'output_filename': 'css/compressed/compressed/forum.css',
79 'css/import/gelasio.css',
80 'css/master.book.css',
81 'css/master.picture.css',
83 'output_filename': 'css/compressed/picture.css',
87 'jplayer/jplayer.blue.monday.css',
90 'output_filename': 'css/compressed/player.css',
93 'source_filenames': ('css/simple.css',),
94 'output_filename': 'css/compressed/simple.css',
97 'source_filenames': ('scss/widget.scss',),
98 'output_filename': 'css/compressed/widget.css',
103 'source_filenames': (
104 'js/contrib/jquery.cycle2.min.js',
105 'js/contrib/jquery.jqmodal.js',
106 'js/contrib/jquery.form.js',
107 'js/contrib/jquery.paging.min.js',
108 'js/contrib/jquery.countdown.js', 'js/contrib/jquery.countdown-pl.js',
109 'js/contrib/jquery.countdown-de.js', 'js/contrib/jquery.countdown-uk.js',
110 'js/contrib/jquery.countdown-es.js', 'js/contrib/jquery.countdown-lt.js',
111 'js/contrib/jquery.countdown-ru.js', 'js/contrib/jquery.countdown-fr.js',
112 'js/contrib/jquery.shorten.js',
114 'js/contrib/jquery-ui-1.8.16.custom.min.js',
116 'js/contrib/tlite.min.js',
118 'jplayer/jquery.jplayer.min.js',
119 'jplayer/jplayer.playlist.min.js',
125 'pdcounter/pdcounter.js',
126 'sponsors/js/sponsors.js',
127 'player/openplayer.js',
129 'funding/funding.js',
134 'output_filename': 'js/base.min.js',
137 'source_filenames': [
138 'jplayer/jquery.jplayer.min.js',
139 'jplayer/jplayer.playlist.min.js',
142 'output_filename': 'js/player.min.js',
145 'source_filenames': [
146 'js/contrib/jquery.eventdelegation.js',
147 'js/contrib/jquery.scrollto.js',
148 'js/contrib/jquery.highlightfade.js',
149 'js/book_text/other.js',
152 'js/contrib/raphael-min.js',
153 'js/contrib/progressSpin.min.js',
156 'output_filename': 'js/book.min.js',
159 'source_filenames': [
160 'js/contrib/jquery.cycle2.min.js',
161 'js/contrib/jquery.form.js',
162 'js/contrib/jquery.jqmodal.js',
163 'js/book_text/info.js',
164 'js/book_text/menu.js',
165 'js/book_text/note.js',
166 'js/book_text/references.js',
167 'js/book_text/settings.js',
168 'js/book_text/toc.js',
171 'annoy/book_text.js',
173 'js/contrib/jquery.highlightfade.js',
174 'js/contrib/raphael-min.js',
175 'player/openplayer.js',
176 'js/contrib/progressSpin.min.js',
179 'output_filename': 'js/book_text.js',
182 'source_filenames': [
185 'output_filename': 'js/picture.min.js',
188 'source_filenames': ('js/contrib/ierange-m2.js',),
189 'output_filename': 'js/book_ie.min.js',
192 'source_filenames': (
193 'js/contrib/jquery.js',
194 'js/contrib/jquery-ui-1.8.16.custom.min.js',
198 'output_filename': 'js/widget.min.js',
201 'CSS_COMPRESSOR': None,
202 'JS_COMPRESSOR': 'pipeline.compressors.jsmin.JSMinCompressor',
204 'libsasscompiler.LibSassCompiler',
208 STATICFILES_STORAGE = 'fnpdjango.pipeline_storage.GzipPipelineCachedStorage'
209 #STATICFILES_STORAGE = 'pipeline.storage.PipelineCachedStorage'
211 # PIPELINE_PYSCSS_BINARY = '/usr/bin/env pyscss'
212 # PIPELINE_PYSCSS_ARGUMENTS = ''
215 STATICFILES_FINDERS = [
216 'django.contrib.staticfiles.finders.FileSystemFinder',
217 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
218 'pipeline.finders.CachedFileFinder',
219 'pipeline.finders.PipelineFinder',
223 from machina import MACHINA_MAIN_STATIC_DIR
225 MACHINA_MAIN_STATIC_DIR,