« get me outta code hell

show which pages are being written right away - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2022-06-28 09:08:01 -0300
committer(quasar) nebula <qznebula@protonmail.com>2022-06-28 09:08:01 -0300
commitf3594c11d1e43b78ece8272ceaaee271fef290eb (patch)
tree6f3617011ea492a66a3f527212aff36ccc9b6f16 /src
parent88c0d66fbb00a14fb2a40b05a89f16f3bec52ec0 (diff)
show which pages are being written right away
Diffstat (limited to 'src')
-rwxr-xr-xsrc/upd8.js44
1 files changed, 22 insertions, 22 deletions
diff --git a/src/upd8.js b/src/upd8.js
index 462507e8..b2d5846c 100755
--- a/src/upd8.js
+++ b/src/upd8.js
@@ -1742,6 +1742,28 @@ async function main() {
   const noBuild = miscOptions['no-build'] ?? false;
   const showAggregateTraces = miscOptions['show-traces'] ?? false;
 
+  // NOT for ena8ling or disa8ling specific features of the site!
+  // This is only in charge of what general groups of files to 8uild.
+  // They're here to make development quicker when you're only working
+  // on some particular area(s) of the site rather than making changes
+  // across all of them.
+  const writeFlags = await parseOptions(process.argv.slice(2), {
+    all: {type: 'flag'}, // Defaults to true if none 8elow specified.
+
+    // Kinda a hack t8h!
+    ...Object.fromEntries(
+      Object.keys(pageSpecs).map((key) => [key, {type: 'flag'}])
+    ),
+
+    [parseOptions.handleUnknown]: () => {},
+  });
+
+  const writeAll = !Object.keys(writeFlags).length || writeFlags.all;
+
+  logInfo`Writing site pages: ${
+    writeAll ? 'all' : Object.keys(writeFlags).join(', ')
+  }`;
+
   const niceShowAggregate = (error, ...opts) => {
     showAggregate(error, {
       showTraces: showAggregateTraces,
@@ -2045,28 +2067,6 @@ async function main() {
 
   const buildDictionary = pageSpecs;
 
-  // NOT for ena8ling or disa8ling specific features of the site!
-  // This is only in charge of what general groups of files to 8uild.
-  // They're here to make development quicker when you're only working
-  // on some particular area(s) of the site rather than making changes
-  // across all of them.
-  const writeFlags = await parseOptions(process.argv.slice(2), {
-    all: {type: 'flag'}, // Defaults to true if none 8elow specified.
-
-    // Kinda a hack t8h!
-    ...Object.fromEntries(
-      Object.keys(buildDictionary).map((key) => [key, {type: 'flag'}])
-    ),
-
-    [parseOptions.handleUnknown]: () => {},
-  });
-
-  const writeAll = !Object.keys(writeFlags).length || writeFlags.all;
-
-  logInfo`Writing site pages: ${
-    writeAll ? 'all' : Object.keys(writeFlags).join(', ')
-  }`;
-
   await writeFavicon();
   await writeSymlinks();
   await writeSharedFilesAndPages({language: finalDefaultLanguage, wikiData});