mirror of
https://github.com/vale981/emacs-ipython-notebook
synced 2025-03-06 01:21:38 -05:00
additions to support clojure/clojpuyter
This commit is contained in:
parent
cfd7a9a117
commit
23faf4a3f5
1 changed files with 14 additions and 0 deletions
|
@ -34,6 +34,7 @@
|
|||
(require 'python)
|
||||
(require 'ess-r-mode nil t)
|
||||
(require 'ess-custom nil t)
|
||||
(require 'clojure-mode nil t)
|
||||
|
||||
(declare-function ess-indent-line "ess")
|
||||
(declare-function ess-r-eldoc-function "ess-r-completion")
|
||||
|
@ -142,6 +143,19 @@ This function may raise an error."
|
|||
(set-syntax-table python-mode-syntax-table)
|
||||
(set-keymap-parent ein:notebook-multilang-mode-map python-mode-map))
|
||||
|
||||
(defun ein:ml-lang-setup-clojure ()
|
||||
"A naive combination of the python and R setups with things from clojure-mode.el"
|
||||
(setq-local mode-name "EIN[Clj]")
|
||||
(setq-local comment-start "; ")
|
||||
(setq-local comment-start-skip ";+\\s-*")
|
||||
(setq-local parse-sexp-lookup-properties t)
|
||||
(setq-local indent-line-function
|
||||
(apply-partially #'ein:ml-indent-line-function #'clojure-indent-line))
|
||||
(setq-local indent-region-function
|
||||
(apply-partially #'ein:ml-indent-region #'clojure-indent-region))
|
||||
(set-syntax-table clojure-mode-syntax-table)
|
||||
(set-keymap-parent ein:notebook-multilang-mode-map clojure-mode-map))
|
||||
|
||||
(defun ein:ml-lang-setup-R ()
|
||||
(when (and (featurep 'ess-r-mode) (featurep 'ess-custom))
|
||||
(setq-local mode-name "EIN[R]")
|
||||
|
|
Loading…
Add table
Reference in a new issue