Skip to content

Commit e11637b

Browse files
committed
Fix about.html generation while excluding from sitemap
- Created separate 'blog-pages' project for standalone pages - Keeps about.org excluded from sitemap but still builds about.html - Fixes CI workflow expectation that about.html should exist - Prevents 'Expected public/about.html not found' error The about page is now accessible via navigation but not listed on homepage.
1 parent 0406f97 commit e11637b

1 file changed

Lines changed: 24 additions & 1 deletion

File tree

build.sh

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,14 +160,37 @@ if emacs --batch \
160160
:sitemap-function blog/sitemap-function
161161
:exclude \"404\\\\.org\\\\|about\\\\.org\")
162162
163+
(\"blog-pages\"
164+
:base-directory ,blog-posts-directory
165+
:base-extension \"org\"
166+
:publishing-directory ,blog-publish-directory
167+
:recursive nil
168+
:publishing-function org-html-publish-to-html
169+
:headline-levels 4
170+
:section-numbers nil
171+
:with-toc t
172+
:with-author t
173+
:with-date t
174+
:html-head ,(concat \"<link rel=\\\"icon\\\" type=\\\"image/svg+xml\\\" href=\\\"/static/favicon.svg\\\">
175+
<link rel=\\\"preconnect\\\" href=\\\"https://fonts.googleapis.com\\\">
176+
<link rel=\\\"preconnect\\\" href=\\\"https://fonts.gstatic.com\\\" crossorigin>
177+
<link href=\\\"https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap\\\" rel=\\\"stylesheet\\\">
178+
<link rel=\\\"stylesheet\\\" type=\\\"text/css\\\" href=\\\"/static/css/blog.css?v=\" (or (getenv \"CSS_VERSION\") \"$CSS_VERSION\") \"\\\" />
179+
<script src=\\\"/static/js/blog.js?v=\" (or (getenv \"JS_VERSION\") \"$JS_VERSION\") \"\\\" defer></script>\")
180+
:html-preamble blog/preamble
181+
:html-postamble blog/postamble
182+
:html-head-include-default-style nil
183+
:html-head-include-scripts nil
184+
:include (\"about.org\"))
185+
163186
(\"blog-static\"
164187
:base-directory ,blog-static-directory
165188
:base-extension \"css\\\\|js\\\\|png\\\\|jpg\\\\|gif\\\\|pdf\\\\|mp3\\\\|ogg\\\\|swf\\\\|svg\\\\|woff\\\\|woff2\\\\|ico\\\\|webp\\\\|avif\"
166189
:publishing-directory ,(concat blog-publish-directory \"static/\")
167190
:recursive t
168191
:publishing-function org-publish-attachment)
169192
170-
(\"blog\" :components (\"blog-posts\" \"blog-static\"))))
193+
(\"blog\" :components (\"blog-posts\" \"blog-pages\" \"blog-static\"))))
171194
172195
;; Publish the blog
173196
(org-publish \"blog\" t)

0 commit comments

Comments
 (0)