ferron

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

commit 4b1ab808292d6d36d62aa3a93e846340951d2ffb
parent 2eff271575b7faaba1c8e99a24a6f02f496f2816
Author: Hugo Soucy <hugo.soucy@equisoft.com>
Date:   Tue, 22 Oct 2019 20:37:36 -0400

Fix some path bug

Diffstat:
Mferron/utilities/file-utils.lua | 6+++++-
1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/ferron/utilities/file-utils.lua b/ferron/utilities/file-utils.lua @@ -206,7 +206,11 @@ end function fileutils.getrellink(file, contentdir) local relpath = fileutils.getrelpath(file, contentdir) - return (fileutils.getplainname(file) ~= 'index' and relpath .. '.html' or '') + return ( + fileutils.getplainname(file) ~= 'index' + and fileutils.removeextension(relpath) .. '.html' + or fileutils.getdirname(relpath) + ) end function fileutils.getpermalink(file, sitedata)