Permalink
Browse files

Add JSOB Feed layout file and tweak config

  • Loading branch information...
mattfoster committed May 27, 2017
1 parent 1320cdd commit e776d9c3457ee60245ff2bb19da9b791c9dd0632
Showing with 25 additions and 4 deletions.
  1. +2 −4 config.toml
  2. +23 −0 layouts/index.json
@@ -7,11 +7,7 @@ title = "Hackerific"
# Copyright
copyright = "(c) 2015-2017 Matt Foster."
# Language
languageCode = "en-EN"
# Metadata format
# "yaml", "toml", "json"
metaDataFormat = "yaml"
# Theme to use (located in /themes/THEMENAME/)
@@ -73,6 +69,8 @@ enableEmoji = true
rss = true
ghribbon = "green-upleft"
description = "A site about hacking, music and electronics"
author = "Matt Foster"
[blackfriday]
@@ -0,0 +1,23 @@
{
"version": "https://jsonfeed.org/version/1",
"title": "{{ .Site.Title }}",
"home_page_url": "{{ .Site.BaseURL }}",
"feed_url": "{{ .Permalink}}",
"description": "{{ .Site.Params.description }}",
"author": { "name": "{{ .Site.Params.author }}" },
"items": [
{{- range $i, $e := first 10 .Site.Pages }}
{{- if $i }}, {{ end }}
{
"title": "{{ .Title }}",
"date_published": "{{ .Date }}",
{{- if isset .Params "link" }}
"external-link": "{{ .Params.link }}",
{{- end }}
"url": "{{ .Permalink }}",
"id": "{{ .Permalink }}",
"content_text": {{ .Summary | jsonify }}
}
{{- end }}
]
}

0 comments on commit e776d9c

Please sign in to comment.