Brad Lucas

Programming, Clojure and other interests
July 7, 2017

Insert Org Mode Line

If you use org-mode a lot you'll eventually look to a way to quickly setup a new file with your favorite settings. Here I use the following to quickly add the org mode line and a few favored settings.

(defconst *org-modeline*  "# -*- mode:org; -*-")
(defconst *org-mode-settings* "
#+STARTUP: showall
#+STARTUP: hidestars
#+OPTIONS: toc:nil
#+OPTIONS: skip:t
#+HTML_HEAD: <link rel=\"stylesheet\" type=\"text/css\" href=\"./org.css\" />
#+OPTIONS: ^:nil


(defun insert-org-modeline ()
    (insert *org-modeline*)
    (insert *org-mode-settings*)

Feel free to add or modify to make the above your own.

Tags: emacs