main.el 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #!/usr/bin/emacs --script
  2. ;; Built for emacs 26.1
  3. ;; (setq debug-on-error t)
  4. (add-to-list 'load-path (expand-file-name "../../bin/htmlize"))
  5. (require 'htmlize)
  6. (require 'ox-publish)
  7. ;; (require 'ox-rss)
  8. (setq org-html-validation-link nil)
  9. (setq ssg-extensions-list "css\\|js\\|png\\|jpg\\|jpeg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|otf\\|ico\\|cgi")
  10. (setq ssg-site-dir ".")
  11. (setq ssg-publish-dir "../../output")
  12. (setq ssg-content
  13. `("ssg-content"
  14. :author nil
  15. :auto-preamble t
  16. :auto-sitemap t
  17. :base-directory ,ssg-site-dir
  18. :base-extension "org"
  19. :creator-info nil
  20. :exclude "family-business*"
  21. :exclude-tags ("noexport" "todo")
  22. :export-with-tags nil
  23. :headline-levels 6
  24. :html-head "<link rel=\"stylesheet\" type=\"text/css\" href=\"static/style/main.css\" />"
  25. ;; :html-postamble nil
  26. ;; :html-preamble nil
  27. ;; :html-style nil
  28. :publishing-directory ,ssg-publish-dir
  29. :publishing-function org-html-publish-to-html
  30. :recursive t
  31. :section-numbers nil
  32. ;; :sitemap-format-entry
  33. :sitemap-title "Sitemap"
  34. :sub-superscript nil
  35. :table-of-contents nil
  36. :timestamp t
  37. :todo-keywords nil
  38. ))
  39. (setq ssg-static
  40. `("ssg-static"
  41. :base-directory ,ssg-site-dir
  42. :base-extension ,ssg-extensions-list
  43. :include (".htaccess")
  44. :publishing-directory ,ssg-publish-dir
  45. :publishing-function org-publish-attachment
  46. :recursive t
  47. ))
  48. (setq ssg
  49. '("ssg"
  50. :components ("ssg-content" "ssg-static")))
  51. (setq org-publish-project-alist
  52. (list ssg-content ssg-static ssg))
  53. (org-publish-project "ssg")