Skip to content

Instantly share code, notes, and snippets.

@shawngraham
Forked from zhuochun/README.md
Created March 21, 2016 22:43

Revisions

  1. @zhuochun zhuochun revised this gist Mar 20, 2015. 1 changed file with 5 additions and 0 deletions.
    5 changes: 5 additions & 0 deletions README.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,5 @@
    # [Markdown-Writer for Atom](https://github.com/zhuochun/md-writer)

    List all posts, tags and categories in Jekyll.

    Octopress users: if you found `"` is escaped in the generated JSON file, please change them to `\"`. Refer to [this issue](https://github.com/zhuochun/md-writer/issues/36).
  2. @zhuochun zhuochun revised this gist Aug 14, 2014. 3 changed files with 3 additions and 3 deletions.
    2 changes: 1 addition & 1 deletion categories.json
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,5 @@
    ---
    layout: none
    layout: null
    ---
    {
    "categories": [
    2 changes: 1 addition & 1 deletion posts.json
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,5 @@
    ---
    layout: none
    layout: null
    ---
    {
    "posts": [
    2 changes: 1 addition & 1 deletion tags.json
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,5 @@
    ---
    layout: none
    layout: null
    ---
    {
    "tags": [
  3. @zhuochun zhuochun revised this gist Aug 2, 2014. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion posts.json
    Original file line number Diff line number Diff line change
    @@ -6,7 +6,7 @@ layout: none
    {% for post in site.posts %}
    {
    "title": "{{ post.title | xml_escape }}",
    "url": "{{site.url}}{{ post.url }}",
    "url": "{{ site.url }}{{ post.url }}",
    "date": "{{ post.date | date_to_xmlschema }}"
    }{% unless forloop.last %},{% endunless %}
    {% endfor %}
  4. @zhuochun zhuochun created this gist Jul 25, 2014.
    10 changes: 10 additions & 0 deletions categories.json
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    ---
    layout: none
    ---
    {
    "categories": [
    {% for category in site.categories %}
    "{{ category | first }}"{% unless forloop.last %},{% endunless %}
    {% endfor %}
    ]
    }
    14 changes: 14 additions & 0 deletions posts.json
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,14 @@
    ---
    layout: none
    ---
    {
    "posts": [
    {% for post in site.posts %}
    {
    "title": "{{ post.title | xml_escape }}",
    "url": "{{site.url}}{{ post.url }}",
    "date": "{{ post.date | date_to_xmlschema }}"
    }{% unless forloop.last %},{% endunless %}
    {% endfor %}
    ]
    }
    10 changes: 10 additions & 0 deletions tags.json
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,10 @@
    ---
    layout: none
    ---
    {
    "tags": [
    {% for tag in site.tags %}
    "{{ tag | first }}"{% unless forloop.last %},{% endunless %}
    {% endfor %}
    ]
    }