mirror of
https://github.com/TREX-CoE/qmckl.git
synced 2025-01-03 10:06:09 +01:00
Modified script for colorized html
This commit is contained in:
parent
09a6402783
commit
69fa53c877
@ -1,6 +1,8 @@
|
||||
(require 'org)
|
||||
(require 'font-lock)
|
||||
;; Thanks to Tobias's answer on Emacs Stack Exchange:
|
||||
;; https://emacs.stackexchange.com/questions/38437/org-mode-batch-export-missing-syntax-highlighting
|
||||
|
||||
(package-initialize)
|
||||
(require 'font-lock)
|
||||
(require 'subr-x) ;; for `when-let'
|
||||
|
||||
(unless (boundp 'maximal-integer)
|
||||
@ -66,22 +68,3 @@ with class 'color and highest min-color value."
|
||||
(or val 'unspecified)))
|
||||
|
||||
(advice-add 'face-attribute :override #'my-face-attribute)
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
;; Debugging:
|
||||
(defmacro print-args-and-ret (fun)
|
||||
"Prepare FUN for printing args and return value."
|
||||
`(advice-add (quote ,fun) :around
|
||||
(lambda (oldfun &rest args)
|
||||
(let ((ret (apply oldfun args)))
|
||||
(message ,(concat "Calling " (symbol-name fun) " with args %S returns %S.") args ret)
|
||||
ret))
|
||||
'((name "print-args-and-ret"))))
|
||||
|
||||
; (print-args-and-ret htmlize-faces-in-buffer)
|
||||
; (print-args-and-ret htmlize-get-override-fstruct)
|
||||
; (print-args-and-ret htmlize-face-to-fstruct)
|
||||
; (print-args-and-ret htmlize-attrlist-to-fstruct)
|
||||
; (print-args-and-ret face-foreground)
|
||||
; (print-args-and-ret face-background)
|
||||
; (print-args-and-ret face-attribute)
|
@ -1,13 +1,8 @@
|
||||
#!/bin/bash
|
||||
INPUT=$1
|
||||
#emacs merged_qmckl.org --batch --eval "(require 'htmlize)" -f org-html-export-to-html --kill
|
||||
emacs \
|
||||
$INPUT \
|
||||
--batch \
|
||||
--eval "(package-initialize)" \
|
||||
-f org-html-export-to-html \
|
||||
--kill
|
||||
|
||||
mv *.html ../docs
|
||||
emacs --batch --load ../docs/config.el $INPUT -f org-html-export-to-html
|
||||
|
||||
mv index.html ../docs
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user