ghwikipp: make_offline_archive: include our stylesheets in the output.

From f41640a09f3a9294ae9727985e5fd5b75e61c606 Mon Sep 17 00:00:00 2001
From: "Ryan C. Gordon" <[EMAIL REDACTED]>
Date: Thu, 9 May 2024 23:44:43 -0400
Subject: [PATCH] make_offline_archive: include our stylesheets in the output.

---
 make_offline_archive.php | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/make_offline_archive.php b/make_offline_archive.php
index 885f484..ee73a64 100755
--- a/make_offline_archive.php
+++ b/make_offline_archive.php
@@ -56,10 +56,11 @@ function cook_tree_for_offline_html($srcdir, $dstdir)
                     if ($pid == -1) {
                         print("FAILED TO FORK!\n");
                     } else if ($pid == 0) {  // child process.
-                         pcntl_exec('/usr/bin/pandoc', [ '--metadata', "pagetitle=$page", '-s', '-f', $from_format, '-t', 'html', '--toc', '--lua-filter=./pandoc-filter-offline.lua', '-o', $dst, $src ]);
-                         exit(1);
+                        pcntl_exec('/usr/bin/pandoc', [ '--metadata', "pagetitle=$page", '--self-contained', '-f', $from_format, '-t', 'html', '--css=static_files/ghwikipp.css', '--css=static_files/pandoc.css', '--lua-filter=./pandoc-filter-offline.lua', '-o', $dst, $src ]);
+                        exit(1);
                     } else {  // parent process.
-                         $num_children++;
+                        $num_children++;
+                        //print("$page\n");
                     }
                 }
             }