~swisschili/blackjack

5044e5c457f61ecd9e0cf1e3c07d0d0199e2baf7 — swissChili 4 months ago a32232c
Add global config data
1 files changed, 4 insertions(+), 2 deletions(-)

M blackjack.lua
M blackjack.lua => blackjack.lua +4 -2
@@ 134,7 134,9 @@ Site = {
      process = mdProcessor,
      extension = 'html'
    }
  }
  },
  -- Global config data
  global = {}
}

local function getExtension(file)


@@ 177,7 179,7 @@ function Site:build()
  local p = io.popen('find "'.. self.content ..'" -type f')
  for file in p:lines() do
    print(" Building: ".. file)
    local html = self:render(file, {})
    local html = self:render(file, self.global)
    local outFile = self.output .. getFileName(
      self,
      replaceExtension(file, self.processors[getExtension(file)].extension)