2020-11-05 15:53:28 +01:00
|
|
|
;; Thanks to Tobias's answer on Emacs Stack Exchange:
|
|
|
|
;; https://emacs.stackexchange.com/questions/38437/org-mode-batch-export-missing-syntax-highlighting
|
2020-10-27 17:24:44 +01:00
|
|
|
|
2021-03-10 12:58:38 +01:00
|
|
|
|
2020-11-05 15:53:28 +01:00
|
|
|
(package-initialize)
|
2021-03-06 19:46:27 +01:00
|
|
|
(add-to-list 'package-archives
|
|
|
|
'("gnu" . "https://elpa.gnu.org/packages/"))
|
|
|
|
(add-to-list 'package-archives
|
|
|
|
'("melpa-stable" . "https://stable.melpa.org/packages/"))
|
|
|
|
(add-to-list 'package-archives
|
|
|
|
'("melpa" . "https://melpa.org/packages/"))
|
|
|
|
(setq package-archive-priorities '(("melpa-stable" . 100)
|
|
|
|
("melpa" . 50)
|
|
|
|
("gnu" . 10)))
|
|
|
|
|
|
|
|
|
2020-11-07 15:41:49 +01:00
|
|
|
(require 'font-lock)
|
2021-03-06 19:46:27 +01:00
|
|
|
(setq org-confirm-babel-evaluate nil)
|
|
|
|
(global-font-lock-mode t)
|
2021-03-10 12:58:38 +01:00
|
|
|
(setq org-src-fontify-natively t)
|
2021-03-06 19:46:27 +01:00
|
|
|
|
|
|
|
(org-babel-do-load-languages
|
|
|
|
'org-babel-load-languages
|
|
|
|
'(
|
|
|
|
(emacs-lisp . t)
|
|
|
|
(shell . t)
|
|
|
|
(python . t)
|
2021-03-10 12:58:38 +01:00
|
|
|
(fortran . t)
|
2021-03-06 19:46:27 +01:00
|
|
|
(C . t)
|
|
|
|
(org . t)
|
|
|
|
(makefile . t)
|
|
|
|
))
|
|
|
|
|
|
|
|
|
2021-03-10 12:58:38 +01:00
|
|
|
; The following is required to compute the file names
|
2021-03-09 01:16:23 +01:00
|
|
|
(setq pwd (file-name-directory buffer-file-name))
|
2021-05-11 11:45:49 +02:00
|
|
|
(setq wd (concat pwd "/../src/"))
|
2021-03-09 01:16:23 +01:00
|
|
|
(setq name (file-name-nondirectory (substring buffer-file-name 0 -4)))
|
2021-05-11 11:45:49 +02:00
|
|
|
(setq f (concat wd name "_f.f90"))
|
|
|
|
(setq fh_func (concat wd name "_fh_func.f90"))
|
|
|
|
(setq fh_type (concat wd name "_fh_type.f90"))
|
|
|
|
(setq c (concat wd name ".c"))
|
|
|
|
(setq h_func (concat wd name "_func.h"))
|
|
|
|
(setq h_type (concat wd name "_type.h"))
|
|
|
|
(setq h_private_type (concat wd name "_private_type.h"))
|
|
|
|
(setq h_private_func (concat wd name "_private_func.h"))
|
|
|
|
(setq c_test (concat wd "test_" name ".c"))
|
|
|
|
(setq f_test (concat wd "test_" name "_f.f90"))
|
2021-03-23 22:23:49 +01:00
|
|
|
(org-babel-lob-ingest "../tools/lib.org")
|
2021-03-09 01:16:23 +01:00
|
|
|
|