satelito

Static [web] site (or page) generator (ssg) made with Lua script.
git clone git://soucy.cc/satelito.git
Log | Files | Refs | README

commit 990263470916bb4a1223aa31617130314a2aa9f1
parent 15f633d8a42ccc8e6e98755b568f57a8ee529bdf
Author: Hugo Soucy <hugo@soucy.cc>
Date:   Mon,  3 Apr 2023 11:15:10 -0400

Merge branch 'master' into dev/2022-12/purge-command

Diffstat:
Msatelito/file.lua | 6+-----
1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/satelito/file.lua b/satelito/file.lua @@ -162,12 +162,8 @@ end -- Create a dirtree function file.mkdir(filepath) local sep, pStr = package.config:sub(1, 1), '' - -- Check if the filepath is absolute or relative - local _filepath = (string.find(filepath, lfs.currentdir()) - and filepath - or lfs.currentdir() .. '/' .. filepath) + local _filepath = lfs.currentdir()..file.get_relpath(filepath, lfs.currentdir()) - -- for dir in _filepath:gmatch('[^' .. sep .. ']+') do pStr = pStr .. sep .. dir lfs.mkdir(pStr)