Sha256: 52fdb977d1344898d587be00e217bbde7f5029ffd9492f9073e23a3b43ad8dc2

Contents?: true

Size: 869 Bytes

Versions: 1

Compression:

Stored size: 869 Bytes

Contents

<?xml version="1.0" encoding="UTF-8"?>
<urlset>
  {% assign timeframe = 172800 %}
  {% assign posts = site.posts | where_exp:'doc','doc.sitemap != false' %}
  {% for post in posts %}
    {% assign post_in_seconds = post.date | date: "%s" | plus: 0 %}
    {% assign recent_posts = "now" | date: "%s" | minus: timeframe  %}
    {% if post_in_seconds > recent_posts %}
      <url>
        <loc>{{ post.url | replace:'/index.html','/' | absolute_url | xml_escape }}</loc>

        <news:news>
          <news:publication>
            <news:name>{{site.publisher}}</news:name>
            <news:language>en</news:language>
          </news:publication>
          <news:publication_date>{{ post.date | date_to_xmlschema }}</news:publication_date>
          <news:title>{{ post.title }}</news:title>
        </news:news>
      </url>
    {% endif %}
  {% endfor %}
</urlset>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jekyll-news-sitemap-0.1.4 lib/sitemap_news.xml