From: Radek Czajka
Date: Thu, 13 May 2010 12:33:01 +0000 (+0200)
Subject: Merge branch 'master' of git+ssh://github.com/fnp/wolnelektury
X-Git-Url: https://git.mdrn.pl/wolnelektury.git/commitdiff_plain/efd819ba16dfc705f20298d4dd4a906d789d8b4d?hp=0ae93a9cec777350e56c870b6dc8772d8541f252
Merge branch 'master' of git+ssh://github.com/fnp/wolnelektury
---
diff --git a/deployment.py b/deployment.py
index b156b9385..ab198801c 100644
--- a/deployment.py
+++ b/deployment.py
@@ -31,7 +31,7 @@ def update_application():
os.system("%s install -r %s" % (PIP, os.path.join(ROOT, 'etc', 'requirements.txt')))
print "done."
-ROOT = os.path.dirname(os.path.abspath(__file__))
+ROOT = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
PYTHON = os.path.join(ROOT, 'pythonenv', 'bin', 'python')
PIP = os.path.join(ROOT, 'pythonenv', 'bin', 'pip')
diff --git a/wolnelektury.vhost.tmpl b/wolnelektury.vhost.tmpl
index fbd21a9a1..6fac7562d 100644
--- a/wolnelektury.vhost.tmpl
+++ b/wolnelektury.vhost.tmpl
@@ -1,6 +1,5 @@
ServerName $DOMAIN
- ServerAlias $DOMAIN_ALIASES
ServerAdmin $ADMIN_EMAIL
WSGIDaemonProcess $PROJECT_NAME user=$WSGI_USER group=$WSGI_USER processes=$WSGI_PROCESSES threads=$WSGI_THREADS display-name=%{GROUP}
@@ -14,7 +13,6 @@
Alias /media $MEDIA_ROOT
- Options Indexes, FollowLinks
Order allow,deny
Allow from all
diff --git a/wolnelektury/context_processors.py b/wolnelektury/context_processors.py
new file mode 100644
index 000000000..0cbf60513
--- /dev/null
+++ b/wolnelektury/context_processors.py
@@ -0,0 +1,6 @@
+
+def extra_settings(request):
+ from django.conf import settings
+ return {
+ 'STATIC_URL': settings.STATIC_URL,
+ }
diff --git a/wolnelektury/settings.py b/wolnelektury/settings.py
index 62a2c9e23..33c219843 100644
--- a/wolnelektury/settings.py
+++ b/wolnelektury/settings.py
@@ -67,6 +67,7 @@ TEMPLATE_CONTEXT_PROCESSORS = [
'django.core.context_processors.i18n',
'django.core.context_processors.media',
'django.core.context_processors.request',
+ 'wolnelektury.context_processors.extra_settings',
]
MIDDLEWARE_CLASSES = [
@@ -96,7 +97,7 @@ INSTALLED_APPS = [
'django.contrib.sites',
'django.contrib.admin',
'django.contrib.admindocs',
-
+
# external
'south',
'sorl.thumbnail',
@@ -131,7 +132,7 @@ COMPRESS_JS = {
'output_filename': 'js/jquery.min.js',
},
'all': {
- 'source_filenames': ('js/jquery.autocomplete.js', 'js/jquery.form.js',
+ 'source_filenames': ('js/jquery.autocomplete.js', 'js/jquery.form.js',
'js/jquery.countdown.js', 'js/jquery.countdown-pl.js',
'js/jquery.jqmodal.js', 'js/jquery.labelify.js', 'js/catalogue.js',
'js/jquery.cookie.js',),
diff --git a/wolnelektury/templates/1percent.html b/wolnelektury/templates/1percent.html
index e53caeefd..d7bbdc0aa 100644
--- a/wolnelektury/templates/1percent.html
+++ b/wolnelektury/templates/1percent.html
@@ -4,10 +4,10 @@
{% block title %}1% podatku na WolneLektury.pl{% endblock title %}
{% block extrahead %}
-
-
-
-
+
+
+
+
{% endblock extrahead %}
{% block bodycontent %}
@@ -15,11 +15,11 @@
@@ -41,7 +41,7 @@
Przy wypeÅnianiu formularza PIT w polu wniosek o przekazanie 1% podatku na rzecz OPP wpisz:
Fundacja Nowoczesna Polska
KRS 0000070056
-
+
Skorzystaj z programu uÅatwiajÄ
cego przygotowanie deklaracji podatkowej on-line.
diff --git a/wolnelektury/templates/404.html b/wolnelektury/templates/404.html
index b4968a248..b761b4866 100644
--- a/wolnelektury/templates/404.html
+++ b/wolnelektury/templates/404.html
@@ -6,12 +6,12 @@
404 - {% trans "Site does not exist" %} - WolneLektury.pl
-
+
-
+
{% trans "Site does not exist" %}
{% trans "We are sorry, but this site does not exist. Please check if you entered correct address or go to "%} {% trans "homepage" %} .
diff --git a/wolnelektury/templates/500.html b/wolnelektury/templates/500.html
index e778d4fbd..702d9a4d8 100644
--- a/wolnelektury/templates/500.html
+++ b/wolnelektury/templates/500.html
@@ -6,12 +6,12 @@
500 - {% trans "Server error" %} WolneLektury.pl
-
+
-
+
{% trans "Server error" %}
{% trans "We are sorry for your inconvenience, but server error occured. We are working on fixing it as soon as possible. Meanwhile, please go to " %}{% trans "homepage" %} .
diff --git a/wolnelektury/templates/base.html b/wolnelektury/templates/base.html
index 7a85fa60e..fdd375cc0 100644
--- a/wolnelektury/templates/base.html
+++ b/wolnelektury/templates/base.html
@@ -6,7 +6,7 @@
{% block title %}WolneLektury.pl{% endblock %}
-
+
{% compressed_css "all" %}
{% compressed_js "jquery" %}
{% compressed_js "all" %}
@@ -14,10 +14,10 @@
{% endblock %}
-
+
{% block bodycontent %}
{% chunk "top-message" %}
@@ -28,7 +28,7 @@
@@ -93,7 +93,7 @@
-
{% trans "Loading" %}
+
{% trans "Loading" %}
{% endblock bodycontent %}
diff --git a/wolnelektury/templates/catalogue/book_detail.html b/wolnelektury/templates/catalogue/book_detail.html
index f4363539f..e4afcb787 100644
--- a/wolnelektury/templates/catalogue/book_detail.html
+++ b/wolnelektury/templates/catalogue/book_detail.html
@@ -41,7 +41,7 @@
{% endif %}
{% if book.mp3_file %}
-
+
{% trans "Artist" %}: {{ book.get_extra_info_value.artist_name }}
{% if book.get_extra_info_value.director_name %}
{% trans "Director" %}: {{ book.get_extra_info_value.director_name }}
@@ -51,8 +51,8 @@
{% if book.mp3_file %}
{% trans "Download MP3" %} {% endif %}
{% if book.ogg_file %}
{% trans "Download Ogg Vorbis" %} {% endif %}
{% if book.mp3_file %}
-
-
+
+
@@ -128,7 +128,7 @@
-
{% trans "Loading" %}
+
{% trans "Loading" %}
{% endblock %}
\ No newline at end of file
diff --git a/wolnelektury/templates/catalogue/book_fragments.html b/wolnelektury/templates/catalogue/book_fragments.html
index 0a90e459c..550787d28 100644
--- a/wolnelektury/templates/catalogue/book_fragments.html
+++ b/wolnelektury/templates/catalogue/book_fragments.html
@@ -32,7 +32,7 @@
-
{% trans "Loading" %}
+
{% trans "Loading" %}
{% endblock %}
\ No newline at end of file
diff --git a/wolnelektury/templates/catalogue/book_stub_detail.html b/wolnelektury/templates/catalogue/book_stub_detail.html
index 5037ecb8f..387e123e9 100644
--- a/wolnelektury/templates/catalogue/book_stub_detail.html
+++ b/wolnelektury/templates/catalogue/book_stub_detail.html
@@ -31,7 +31,7 @@
-
Åadowanie
+
Åadowanie
{% endblock %}
\ No newline at end of file
diff --git a/wolnelektury/templates/catalogue/book_text.html b/wolnelektury/templates/catalogue/book_text.html
index 55eef8ebd..2b800f5b9 100644
--- a/wolnelektury/templates/catalogue/book_text.html
+++ b/wolnelektury/templates/catalogue/book_text.html
@@ -6,7 +6,7 @@
{% block title %}WolneLektury.pl{% endblock %}
-
+
{% compressed_css "book" %}
{% compressed_js "jquery" %}
{% compressed_js "book" %}
@@ -20,7 +20,7 @@
diff --git a/wolnelektury/templates/catalogue/main_page.html b/wolnelektury/templates/catalogue/main_page.html
index be6d9004f..defa62a6f 100644
--- a/wolnelektury/templates/catalogue/main_page.html
+++ b/wolnelektury/templates/catalogue/main_page.html
@@ -43,7 +43,7 @@
{% trans " See more" %} â
diff --git a/wolnelektury/templates/catalogue/search_no_hits.html b/wolnelektury/templates/catalogue/search_no_hits.html
index 8e4e788a4..764260651 100644
--- a/wolnelektury/templates/catalogue/search_no_hits.html
+++ b/wolnelektury/templates/catalogue/search_no_hits.html
@@ -17,7 +17,7 @@
-
Åadowanie
+
Åadowanie
{% endblock %}
\ No newline at end of file
diff --git a/wolnelektury/templates/catalogue/tagged_object_list.html b/wolnelektury/templates/catalogue/tagged_object_list.html
index d36fb1d57..9f269e1a2 100644
--- a/wolnelektury/templates/catalogue/tagged_object_list.html
+++ b/wolnelektury/templates/catalogue/tagged_object_list.html
@@ -39,7 +39,7 @@
TXT do czytania na maÅych ekranach, np. na komórce
MP3 do sÅuchania w ulubionym odtwarzaczu MP3
Ogg Vorbis do sÅuchania — otwarty format Fundacji Xiph.Org
-
Uaktualniam listÄ formatów ksiÄ
żek na póÅce. lub anuluj
+
Uaktualniam listÄ formatów ksiÄ
żek na póÅce. lub anuluj
@@ -127,7 +127,7 @@
-
Åadowanie
+
Åadowanie
{% endblock %}
\ No newline at end of file
diff --git a/wolnelektury/templates/info/voluntary_services.html b/wolnelektury/templates/info/voluntary_services.html
index b835671b3..01daa5ec7 100644
--- a/wolnelektury/templates/info/voluntary_services.html
+++ b/wolnelektury/templates/info/voluntary_services.html
@@ -41,14 +41,14 @@
- Raport z realizacji projektu âWolontariat dla wiedzy" .
+ Raport z realizacji projektu âWolontariat dla wiedzy" .
-
-
-
-
-
+
+
+
+
+
diff --git a/wolnelektury/wolnelektury.fcgi b/wolnelektury/wolnelektury.fcgi
deleted file mode 100644
index 51157583e..000000000
--- a/wolnelektury/wolnelektury.fcgi
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env python
-import os
-from os.path import abspath, dirname, join
-import sys
-
-# Redirect sys.stdout to sys.stderr for bad libraries like geopy that use
-# print statements for optional import exceptions.
-sys.stdout = sys.stderr
-
-# Add apps and lib directories to PYTHONPATH
-sys.path.insert(0, abspath(join(dirname(__file__), '../apps')))
-sys.path.insert(0, abspath(join(dirname(__file__), '../lib')))
-
-# Emulate manage.py path hacking.
-sys.path.insert(0, abspath(join(dirname(__file__), "../")))
-sys.path.insert(0, abspath(join(dirname(__file__), ".")))
-
-# Run Django
-os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
-
-from django.core.servers.fastcgi import runfastcgi
-runfastcgi(method='threaded', daemonize='false')
-
diff --git a/wolnelektury/wolnelektury.wsgi b/wolnelektury/wolnelektury.wsgi
deleted file mode 100644
index acafede9c..000000000
--- a/wolnelektury/wolnelektury.wsgi
+++ /dev/null
@@ -1,23 +0,0 @@
-#!/usr/bin/env python
-import os
-from os.path import abspath, dirname, join
-import sys
-
-# Redirect sys.stdout to sys.stderr for bad libraries like geopy that use
-# print statements for optional import exceptions.
-sys.stdout = sys.stderr
-
-# Add apps and lib directories to PYTHONPATH
-sys.path.insert(0, abspath(join(dirname(__file__), '../apps')))
-sys.path.insert(0, abspath(join(dirname(__file__), '../lib')))
-
-# Emulate manage.py path hacking.
-sys.path.insert(0, abspath(join(dirname(__file__), "../")))
-sys.path.insert(0, abspath(join(dirname(__file__), ".")))
-
-# Run Django
-os.environ['DJANGO_SETTINGS_MODULE'] = 'settings'
-
-from django.core.handlers.wsgi import WSGIHandler
-application = WSGIHandler()
-