ferron

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

commit a8ae1d029d82b0153dd7962ec9590c5b07cb1fa3
parent 9b0c4da8d77819276f6135a564fd80b42e484e8d
Author: Hugo Soucy <hugo@soucy.cc>
Date:   Mon, 27 Nov 2017 19:55:08 -0500

Remove useless code.

Diffstat:
Mfunctions/dispatch-nontextuals.lua | 7++-----
Mfunctions/make-lists-of-pages.lua | 4+---
2 files changed, 3 insertions(+), 8 deletions(-)

diff --git a/functions/dispatch-nontextuals.lua b/functions/dispatch-nontextuals.lua @@ -5,8 +5,7 @@ local path = require("path") local tableutils = require("functions.table-utils") local function dispatchnontextuals(file, filesection) - local mimestable = {"image/svg+xml", "image/jpeg", "image/png", "application/pdf"} - local prefetchtable = {} + local mimestable = {"image/svg+xml", "image/jpeg", "image/png", "application/pdf"} path.each( path.dirname(file) .. "/*", "f", @@ -24,9 +23,7 @@ local function dispatchnontextuals(file, filesection) -- Then symlinks from those non-textuals for list index pages lfs.link("." .. img_relpath, htmlfolder .. "/" .. img_section .. "/" .. img_name, true) - prefetchtable[#prefetchtable + 1] = Ferron.site.config.SITE.BASEURL .. "/" .. img_section .. img_relpath - - --print(Ferron.site.config.SITE.BASEURL .. "/" .. img_section .. img_relpath) + --prefetchtable[#prefetchtable + 1] = Ferron.site.config.SITE.BASEURL .. "/" .. img_section .. img_relpath end end, {recurse = true} diff --git a/functions/make-lists-of-pages.lua b/functions/make-lists-of-pages.lua @@ -44,9 +44,7 @@ local function makelistsofpages() fileutils.mkdir(listindex_pathhtml) end - dispatchnontextuals(listindex, listindex_section) - - print(inspect(prefetchtable)) + dispatchnontextuals(listindex, listindex_section) -- Build the HTML file fileutils.pushfilecontent(