93 lines
2.8 KiB
EmacsLisp
93 lines
2.8 KiB
EmacsLisp
;; The following lines are always needed. Choose your own keys.
|
|
;; Org mode keys
|
|
(global-set-key "\C-cl" 'org-store-link)
|
|
(global-set-key "\C-ca" 'org-agenda)
|
|
(global-set-key "\C-cc" 'org-capture)
|
|
(global-set-key "\C-cb" 'org-iswitchb)
|
|
|
|
;; Make windmove work in Org mode:
|
|
(add-hook 'org-shiftup-final-hook 'windmove-up)
|
|
(add-hook 'org-shiftleft-final-hook 'windmove-left)
|
|
(add-hook 'org-shiftdown-final-hook 'windmove-down)
|
|
(add-hook 'org-shiftright-final-hook 'windmove-right)
|
|
|
|
;; org publish
|
|
(require 'ox-publish)
|
|
(setq org-publish-project-alist
|
|
'(("org-notes"
|
|
:base-directory "~/repos/csphy/website/org/"
|
|
:base-extension "org"
|
|
:publishing-directory "~/repos/csphy/website/jekyll/"
|
|
:recursive t
|
|
:publishing-function org-html-publish-to-html
|
|
:headline-leves 4 ;Just the default for this project.
|
|
:html-extension "html"
|
|
:body-only f ;; Only export section between <body> </body>
|
|
)
|
|
|
|
("org-static"
|
|
:base-directory "~/repos/csphy/website/org/"
|
|
:base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf\\|php"
|
|
:publishing-directory "~/repos/csphy/website/"
|
|
:recursive t
|
|
:publishing-function org-publish-attachment
|
|
)
|
|
|
|
("org" :components ("org-notes" "org-static"))))
|
|
|
|
;; preserve indentation on output
|
|
(setq org-src-preserve-indentation t)
|
|
|
|
;; some config for org-babel
|
|
(setq org-confirm-babel-evaluate nil
|
|
org-src-fontify-natively t
|
|
org-src-tab-acts-natively t
|
|
org-hide-emphasis-markers t)
|
|
|
|
;; use js2-mode instead of js-mode in org-mode
|
|
(add-to-list 'org-src-lang-modes
|
|
'("javascript" . js2))
|
|
|
|
;; load languages babel
|
|
(org-babel-do-load-languages
|
|
'org-babel-load-languages
|
|
'((C . t)
|
|
(js . t)
|
|
(emacs-lisp . t)
|
|
;(eukleides . t) TODO search for ob-eukleides
|
|
(haskell . t)
|
|
(scheme . t)
|
|
(shell . t)))
|
|
|
|
;;bullets in org-mode
|
|
;;(require 'org-bullets)
|
|
;;(add-hook 'org-mode-hook (lambda () (org-bullets-mode 1)))
|
|
|
|
;; default apps to open files with org-mode
|
|
(setq org-file-apps
|
|
(quote
|
|
((auto-mode . emacs)
|
|
("\\.mm\\'" . default)
|
|
("\\.x?html?\\'" . "seamonkey")
|
|
("\\.pdf\\'" . "emacsclient %s")
|
|
("\\.djvu\\'" . "djview %s"))))
|
|
|
|
;; define sequence of TODO keywords
|
|
(setq org-todo-keywords
|
|
'((sequence "TODO" "IN PROGRESS" "|" "DONE")))
|
|
|
|
;; org-ref
|
|
;(require 'org-ref)
|
|
|
|
(setq reftex-default-bibliography '("~/repos/csphy/pesquisa/vis.bib"))
|
|
(setq org-ref-bibliography-notes "~/repos/csphy/pesquisa/paper-notes.org"
|
|
org-ref-default-bibliography '("~/repos/csphy/pesquisa/vis.bib")
|
|
org-ref-pdf-directory "~/repos/csphy/pesquisa/vis")
|
|
|
|
;; Use biber to process bibtex
|
|
(setq org-latex-pdf-process
|
|
'("xelatex -interaction nonstopmode -output-directory %o %f"
|
|
"biber %b"
|
|
"xelatex -interaction nonstopmode -output-directory %o %f"
|
|
"xelatex -interaction nonstopmode -output-directory %o %f"))
|