From c703b709481989b38e867200810be7d23792ec9c Mon Sep 17 00:00:00 2001 From: Flame Sage Date: Sat, 10 Nov 2018 06:01:26 +0000 Subject: [PATCH] Left Sidebar. Wiki_markdown default empty string. --- compatdb/app.js | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/compatdb/app.js b/compatdb/app.js index 4b66d26..4501ee2 100644 --- a/compatdb/app.js +++ b/compatdb/app.js @@ -36,10 +36,6 @@ function gitPull(directory, repository) { } } -async function getDirectories(x) { - return fs.readdir(x).filter(file => fs.lstatSync(path.join(x, file)).isDirectory()) -} - async function run() { // Make sure the output directories in Hugo exist. [fsPathHugoContent, fsPathHugoBoxart, fsPathHugoIcon, fsPathHugoSavefiles, fsPathHugoScreenshots].forEach(function (path) { @@ -122,11 +118,11 @@ async function run() { } // Clear out the wiki markdown so it won't be stored with the metadata. - let wikiText = x.wiki_markdown + let wikiText = x.wiki_markdown || '' x.wiki_markdown = null let meta = tomlify.toToml(x, {space: 2}) - let contentOutput = `+++\r\n${meta}\r\n+++\r\n\r\n${wikiText}\r\n`; + let contentOutput = `+++\r\nleft_sidebar = true\r\n${meta}\r\n+++\r\n\r\n${wikiText}\r\n`; await fs.writeFile(`${fsPathHugoContent}/${x.id}.md`, contentOutput);