lanas wrote:
Hi all,
I would like to convert an org file to HTML, much like C-c C-e h
would do, automatically from a shell script. So far I've tried
unsuccesfully some permutaions of:
emacs -batch -l ~/.emacs -eval '(org-export-as-html "./file.org")'
emacs -batch -l ~/.emacs -eval '(org-export-as-html)' ./file.org
Is it at all possible and if so, what would be the actual way of
calling emacs to do this ?
I use a makefile entry
%.html: %.org org-export-cust.el
emacs --batch -q $< -l ./org-export-cust.el
tidy -i -m $@
together with this org-export-cust.el script:
;; Batch script to convert %.org to %.html, with external style sheet
;; and other options.
;;
;; Used via emacs --batch -q $< -l ./org-export-cust.el
;;
(load-library "~/emacs/lisp/org.elc")
(setq org-export-html-style
"<link rel=stylesheet href=\"l3style.css\" type=\"text/css\">")
(org-export-as-html 3 'hidden)
-- Michael
_______________________________________________
Emacs-orgmode mailing list
Remember: use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode