summaryrefslogtreecommitdiff
path: root/build-docs.el
diff options
context:
space:
mode:
authorThanos Apollo <[email protected]>2023-03-26 11:02:04 +0300
committerThanos Apollo <[email protected]>2023-03-26 11:02:04 +0300
commitf037057af0c051e63cb2d74d613947035a9ab3c7 (patch)
tree343a360c3d5190c358a1fa1db70f979c6a3007f8 /build-docs.el
parentfad531b6541d7ae05dfcc55a164778d8c2baa465 (diff)
Add build-docs.el
Diffstat (limited to 'build-docs.el')
-rw-r--r--build-docs.el31
1 files changed, 31 insertions, 0 deletions
diff --git a/build-docs.el b/build-docs.el
new file mode 100644
index 0000000..01e13c1
--- /dev/null
+++ b/build-docs.el
@@ -0,0 +1,31 @@
+(require 'package)
+(setq package-user-dir (expand-file-name "./.packages"))
+(setq package-archives '(("melpa" . "https://melpa.org/packages/")
+ ("elpa" . "https://elpa.gnu.org/packages/")))
+
+;; Initialize the package system
+(package-initialize)
+(unless package-archive-contents
+ (package-refresh-contents))
+
+;; Load the publishing system
+(require 'ox-publish)
+
+(setq org-publish-project-alist
+ (list
+ (list "org-site:main"
+ :recursive nil
+ :base-extension "org"
+ :base-directory "./org"
+ :publishing-function 'org-md-publish-to-md
+ :publishing-directory "./"
+ :with-author nil ;; Don't include author name
+ :with-creator t ;; Include Emacs and Org versions in footer
+ :with-toc nil ;; Include a table of contents
+ :section-numbers nil ;; Don't include section numbers
+ :time-stamp-file nil))) ;; Don't include time stamp in file
+
+;; Generate the site output
+(org-publish-all t)
+
+(message "Build complete!")