Comments (6)
I don't know how to fix this yet, but I did find the problem: for .rst files, the <!-- PELICAN_END_SUMMARY -->
marker gets HTML-escaped before the summary scanner runs, so it gets <!-- PELICAN_END_SUMMARY -->
and doesn't recognize the end marker.
To fix this, either the scanner needs to run before HTML escaping happens, or the scanner should HTML-escape the markers that it's looking for.
from pelican-plugins.
While I cannot provide a fix for the escaping in the summary plugin itself, using a raw role provides a workaround. While the use of raw is discouraged in rst (because it forces the output format), it shouldn't be a problem within pelican, as the target platform is html anyway.
.. raw:: html
<!-- PELICAN_END_SUMMARY -->
from pelican-plugins.
what I ended up doing was to use settings.py
to change the markers into something that doesn't get escaped:
SUMMARY_BEGIN_MARKER = "!BEGIN-SUMMARY!"
SUMMARY_END_MARKER = "!END-SUMMARY!"
Works for me: the plugin strips the markers, so they don't actually need to be comments.
from pelican-plugins.
This is a documentation lack if anything. For reST, the proper way to mark a comment is to have to periods at the start of the line (..
). When placing the summary markers like that, everything works fine:
.. PELICAN_BEGIN_SUMMARY
Some content.
.. PELICAN_END_SUMMARY
This part of the post is not included in the summary.
from pelican-plugins.
/me nods. Although I suspect that would force you to use whole paragraphs as the summary (instead of allowing the use of just a few sentences, which sometimes flows better).
from pelican-plugins.
Yeah, that is a limitation. The alternative is changing the marker of
course. I find paragraphs work well enough but YMMV.
On Jun 9, 2014 10:26 PM, "Brian Warner" [email protected] wrote:
/me nods. Although I suspect that would force you to use whole paragraphs
as the summary (instead of allowing the use of just a few sentences, which
sometimes flows better).—
Reply to this email directly or view it on GitHub
#151 (comment)
.
from pelican-plugins.
Related Issues (20)
- [New Plugin] Enhanced Unfurls
- [New Plugin] pelican-to-sqlite HOT 1
- Cannot load i18n_subsites HOT 2
- [new_plugin] minification HOT 25
- [New Plugin]: i18n Template HOT 4
- [New Plugin] interrefs
- [New plugin] Parser for BibTeX literature files
- [asciidoc_reader] Custom AsciiDoc command HOT 3
- When does extract_toc populate article.toc? HOT 1
- [i18n_subsites] Incorrect reference to parent theme from subsites HOT 1
- [md_inline_extension] Broken with Markdown >= 3.4
- Asking to move some plugins in the Pelican plugin repo HOT 14
- [github_activity] Readme.rst has wrong reference to library used by plugin
- An alternate presentation of pelican-plugins and legacy plugins repos
- [org_python_reader] TRANSLATION property is not respected
- [New Plugins] spellcheck, uniquotes, redirects
- [New plugin] reStructuredText footnotes
- [Migration] - Readtime HOT 1
- [migration] asciidoc_reader HOT 5
- [migration] headerid HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pelican-plugins.