1
0
Fork 0
forked from github/pelican
pelican-theme/pelican
Dirk Makowski 5e45aaab78 Patch to allow relative ASSET_URL
Previously, webassets' ASSET_URL always was absolute.
This patch allows a relative ASSET_URL, depending on Pelican's
RELATIVE_URLS setting.

Hint for templates:
-------------------
Current version of webassets seem to remove any relative
paths at the beginning of the URL. So, if RELATIVE_URLS
is on, ASSET_URL will start with 'theme/', regardless if we
set assets_url here to './theme/' or to 'theme/'.
XXX However, this breaks the ASSET_URL if user navigates to
a sub-URL, e.g. if he clicks on a category. To workaround this
issue, I use
    <link rel="stylesheet" href="{{ SITEURL }}/{{ ASSET_URL }}">
instead of
    <link rel="stylesheet" href="{{ ASSET_URL }}">

Maybe this hint is worth to be included in the documentation.
I have it also written as comments in the source.
2012-10-12 23:01:50 +02:00
..
plugins pep8-ify 2012-07-12 15:29:08 +02:00
themes Add Gittip to social icons. 2012-08-31 23:12:09 -04:00
tools Improve devserver durability. Refs #473. 2012-08-27 13:09:25 -07:00
__init__.py Added a new signal finalized that is dispatched when pelican finishes. 2012-10-12 23:01:50 +02:00
contents.py Deep copy _DEFAULT_SETTINGS instead of linking. 2012-08-29 13:36:15 -07:00
generators.py Patch to allow relative ASSET_URL 2012-10-12 23:01:50 +02:00
log.py pelican/log.py simplified a bit 2012-03-25 18:47:14 +02:00
paginator.py PEP8-ify. 2012-03-09 16:21:38 +01:00
readers.py update typogrify support 2012-07-26 22:02:06 +02:00
rstdirectives.py Add support for abbreviations to reST translator (fixes #395). 2012-07-17 13:30:06 +02:00
settings.py Add new setting EXTRA_TEMPLATES_PATHS 2012-09-03 00:57:23 +01:00
signals.py Added a new signal finalized that is dispatched when pelican finishes. 2012-10-12 23:01:50 +02:00
utils.py Implemented better "valid files not found" behavior. 2012-08-23 12:44:22 -07:00
writers.py strip tags for feed titles 2012-05-11 21:58:10 +02:00