-
Notifications
You must be signed in to change notification settings - Fork 143
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
20 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,25 @@ | ||
language: python | ||
|
||
python: | ||
- "2.7" | ||
- "3.4" | ||
- "2.7" | ||
|
||
env: | ||
- TOXENV=py27-d15 | ||
- TOXENV=py27-d16 | ||
- TOXENV=py27-d17 | ||
- TOXENV=py33-d17 | ||
- TOXENV=cov | ||
- TOXENV=py27-d16 | ||
- TOXENV=py27-d17 | ||
- TOXENV=py34-d17 | ||
- TOXENV=cov | ||
|
||
branches: | ||
only: | ||
- master | ||
- develop | ||
- master | ||
- develop | ||
|
||
install: pip install --quiet --use-mirrors tox | ||
|
||
script: tox | ||
|
||
after_script: | ||
- if [ $TOXENV == "cov" ]; then | ||
pip install --quiet --use-mirrors coveralls; | ||
coveralls; | ||
fi | ||
- if [ $TOXENV == "cov" ]; then | ||
pip install --quiet --use-mirrors coveralls; | ||
coveralls; | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,7 +40,7 @@ Requirements | |
============ | ||
|
||
- python >= 2.7 | ||
- django >= 1.5 | ||
- django >= 1.6 | ||
- markdown | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,14 @@ | ||
from django.apps import apps | ||
from django.conf import settings | ||
from django.template import Library | ||
|
||
register = Library() | ||
|
||
_static = None | ||
if 'django.contrib.staticfiles' in settings.INSTALLED_APPS: | ||
from django.contrib.staticfiles.templatetags.staticfiles import static as _static | ||
else: | ||
from django.templatetags.static import static as _static | ||
|
||
|
||
@register.simple_tag | ||
def static(path): | ||
global _static | ||
if _static is None: | ||
if apps.is_installed('django.contrib.staticfiles'): | ||
from django.contrib.staticfiles.templatetags.staticfiles import static as _static | ||
else: | ||
from django.templatetags.static import static as _static | ||
return _static(path) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters