1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-12-26 10:49:38 +00:00

babel: ensuring each language defined (possibly empty) default header arguments

this makes customization easier when users can assume that
  org-babel-default-header-args:foo will exist for every language
This commit is contained in:
Eric Schulte 2010-06-25 10:12:54 -07:00
parent b2dcd211f1
commit 05ac8eb8a8
15 changed files with 30 additions and 0 deletions

View File

@ -36,6 +36,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("c++" . "cpp"))
(defvar org-babel-default-header-args:C '())
(defvar org-babel-C-compiler "gcc"
"Command used to compile a C source code file into an
executable.")

View File

@ -35,6 +35,8 @@
pagecentre colormodel useDingbats horizontal)
"R-specific header arguments.")
(defvar org-babel-default-header-args:R '())
(defun org-babel-expand-body:R (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body."
(let* ((processed-params (or processed-params

View File

@ -45,6 +45,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("clojure" . "clj"))
(defvar org-babel-default-header-args:clojure '())
(defvar org-babel-clojure-wrapper-method
"
(defn spit

View File

@ -30,6 +30,8 @@
;;; Code:
(require 'ob)
(defvar org-babel-default-header-args:css '())
(defun org-babel-expand-body:css (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body." body)

View File

@ -46,6 +46,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("haskell" . "hs"))
(defvar org-babel-default-header-args:haskell '())
(defvar org-babel-haskell-lhs2tex-command "lhs2tex")
(defvar org-babel-haskell-eoe "\"org-babel-haskell-eoe\"")

View File

@ -39,6 +39,8 @@
(require 'matlab)
(require 'ob-octave)
(defvar org-babel-default-header-args:matlab '())
(defvar org-babel-matlab-shell-command "matlab -nosplash"
"Shell command to use to run matlab as an external process.")

View File

@ -41,6 +41,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("ocaml" . "ml"))
(defvar org-babel-default-header-args:ocaml '())
(defvar org-babel-ocaml-eoe-indicator "\"org-babel-ocaml-eoe\";;")
(defvar org-babel-ocaml-eoe-output "org-babel-ocaml-eoe")

View File

@ -33,6 +33,8 @@
(require 'ob)
(require 'octave-inf)
(defvar org-babel-default-header-args:octave '())
(defvar org-babel-octave-shell-command "octave -q"
"Shell command to use to run octave as an external process.")

View File

@ -31,6 +31,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("perl" . "pl"))
(defvar org-babel-default-header-args:perl '())
(defun org-babel-expand-body:perl (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body."
(let ((vars (second (or processed-params (org-babel-process-params params)))))

View File

@ -34,6 +34,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("python" . "py"))
(defvar org-babel-default-header-args:python '())
(defun org-babel-expand-body:python (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body."
(concat

View File

@ -42,6 +42,8 @@
(add-to-list 'org-babel-tangle-lang-exts '("ruby" . "rb"))
(defvar org-babel-default-header-args:ruby '())
(defun org-babel-expand-body:ruby (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body."
(let ((vars (second (or processed-params (org-babel-process-params params)))))

View File

@ -42,6 +42,8 @@
(require 'ob)
(require 'sass-mode)
(defvar org-babel-default-header-args:sass '())
(defun org-babel-expand-body:sass (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body." body)

View File

@ -41,6 +41,8 @@
(declare-function org-babel-comint-with-output "ob-comint" (meta &rest body))
(declare-function orgtbl-to-generic "org-table" (table params))
(defvar org-babel-default-header-args:sh '())
(defvar org-babel-sh-command "sh"
"Command used to invoke a shell. This will be passed to
`shell-command-on-region'")

View File

@ -45,6 +45,8 @@
;;; Code:
(require 'ob)
(defvar org-babel-default-header-args:sql '())
(defun org-babel-expand-body:sql (body params &optional processed-params)
"Expand BODY according to PARAMS, return the expanded body." body)

View File

@ -29,6 +29,8 @@
;;; Code:
(require 'ob)
(defvar org-babel-default-header-args:sqlite '())
(defun org-babel-expand-body:sqlite
(body params &optional processed-params) body)