I have a blog based on Octopress. It generates an RSS
-feed, but that feed contains whole pages (posts) with images included.
How can I "shrink" it, so it would contain only headers of pages (posts)?
Octopress: 2.0
Jekyll: 2.0.3
In feed.xml, instead of using post.content
, you can use post.excerpt
.
Two solutions :
Add a <!-- more -->
in your posts to mark the limit between post.excerpt
and post.content
. content
still contains both.
Remove this line excerpt_separator: <!--more-->
from your config file. As the default excerpt separator is "\n\n"
(two new lines) excerpt will be created autoamtically.
Use the truncate filter {{ post.content | truncate: 200 | expand_urls: site.url | cdata_escape }}
You will find more information about excerpt in Jekyll documentation