(define-key org-mode-map (kbd "C-c C-b") '
(lambda()(interactive)
(let ((stars (make-string (org-current-level) ?*)))
(insert
(format
"%s%s \n#+begin_src emacs-lisp\n%s#+end_src\n%s"
(if current-prefix-arg "#+end_src\n\n") stars (delete-and-extract-region (region-beginning) (region-end)) (if current-prefix-arg (concat "\n" stars " \n#+begin_src emacs-lisp")))))))
--
My Emacs Files At GitHub
No comments:
Post a Comment