ferron

Ferron is a fast and simple static website generator made with Lua.
Log | Files | Refs | Submodules | README | LICENSE

commit 5d71276cc296b820fc436fe079c3ef96e498ac87
parent 018520310ab854e74d23f63eecbcc58a1a9e406f
Author: Hugo Soucy <hugo@soucy.cc>
Date:   Thu,  9 Aug 2018 20:59:48 -0400

Remove references about `section`

Diffstat:
Mferron/list.lua | 2+-
Mferron/page.lua | 14++++++++++----
2 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/ferron/list.lua b/ferron/list.lua @@ -114,7 +114,7 @@ function list.makelist() list_conf["entries"] = nil list_conf["site"] = nil - fileutils.pushfilecontent(list_noextension .. ".json", json.encode(list_conf, {indent = true, keyorder = {"bridgy","cite","citeurl","content","date","datetime","description","id","keywords","permalink","section","template","title","updated"}})) + fileutils.pushfilecontent(list_noextension .. ".json", json.encode(list_conf, {indent = true, keyorder = {"bridgy","cite","citeurl","content","date","datetime","description","id","keywords","permalink","template","title","updated"}})) end end, { diff --git a/ferron/page.lua b/ferron/page.lua @@ -39,7 +39,6 @@ function page.makepage() page_conf_mt.updated = os.date("%Y-%m-%dT%H:%M:%S", path.mtime(page)) page_conf_mt.permalink = Ferron.site.siteconfig.baseurl .. (page_plainname ~= "index" and page_relpath .. ".html" or "") page_conf_mt.rellink = (page_plainname ~= "index" and page_relpath .. ".html" or "") - page_conf_mt.section = nil page_conf_mt["site"] = Ferron.site.siteconfig -- If exists set the shortlink @@ -49,6 +48,7 @@ function page.makepage() Ferron.site.pagestable[page_key] = page_conf_mt + -- If the ancestors of the page dosen't exists make it if not path.isdir(page_htmlpath) then fileutils.mkdir(page_htmlpath) end @@ -67,10 +67,16 @@ function page.makepage() print(" !! " .. page_relpath .. ".html - error!") end - page_conf.updated = nil - -- Update the JSON file data - fileutils.pushfilecontent(page_noextension .. ".json", json.encode(page_conf, {indent = true, keyorder = {"bridgy","cite","citeurl","content","date","datetime","description","id","keywords","permalink","section","shortlink","template","title"}})) + fileutils.pushfilecontent( + page_noextension .. ".json", + json.encode( + page_conf, { + indent = true, + keyorder = {"bridgy","cite","citeurl","content","date","datetime","description","id","keywords","permalink","shortlink","template","title"} + } + ) + ) end end, {