WIP: use render function successfully
This commit is contained in:
18
site.moon
18
site.moon
@@ -18,9 +18,22 @@ posts = (path=".") ->
|
||||
files = [file for file in lfs.dir path when file != "." and file != ".."]
|
||||
{join(path, file), target(file, "/posts") for _, file in ipairs files}
|
||||
|
||||
-- renderer = require "sitegen.renderers.html"
|
||||
|
||||
|
||||
-- Change output dir to what Openresty prefers
|
||||
site!
|
||||
site.config.out_dir = "html/"
|
||||
-- site = site!
|
||||
-- site.config.out_dir = "html/"
|
||||
|
||||
-- oof = site!
|
||||
|
||||
-- templates = site.templates
|
||||
|
||||
-- require"moon".p [k for k,v in pairs templates]
|
||||
-- require"moon".p [k for k,v in pairs site.templates]
|
||||
-- require"moon".p templates
|
||||
-- require"moon".p renderer.Renderer.can_load("test.md")
|
||||
-- require"moon".p renderer\helpers!
|
||||
|
||||
css = tools.system_command "cat < %s > %s", "css"
|
||||
|
||||
@@ -31,4 +44,5 @@ sitegen.create =>
|
||||
add "index.md"
|
||||
add path, target: target for path, target in pairs posts "docs"
|
||||
|
||||
|
||||
build css, "app.css"
|
||||
|
||||
Reference in New Issue
Block a user