From mboxrd@z Thu Jan 1 00:00:00 1970 From: "R. Michael Weylandt" Subject: Re: Prepare release 8.2.6 Date: Sat, 5 Apr 2014 12:45:41 -0400 Message-ID: References: <87ha6adikd.fsf@bzg.ath.cx> <4C681CE3-580A-4C68-A745-FD0CCF115E0C@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:46319) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WWTjI-0003J3-8N for emacs-orgmode@gnu.org; Sat, 05 Apr 2014 12:46:05 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WWTjH-0005wO-7U for emacs-orgmode@gnu.org; Sat, 05 Apr 2014 12:46:04 -0400 In-Reply-To: <4C681CE3-580A-4C68-A745-FD0CCF115E0C@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Bastien Cc: "emacs-orgmode@gnu.org" On Fri, Apr 4, 2014 at 10:32 AM, Michael Weylandt wrote: > > > On Apr 3, 2014, at 2:37, Bastien wrote: > >> Hi all, >> >> I'll try to fix a few remaining bugs in maint this afternoon >> then release 8.2.6 so that we can merge it into Emacs emacs-24 >> branch, the pretest is scheduled to happen as soon as possible. >> >> If you have important bugs you want us to look at, now is the >> time to point at them. > > A few more minor things from my .emacs: > > 1) In ox-latex.el, add a `downcase` around the definition of mint-lang in= org-latex-inline-src-block and the sexp `(or (cadr (assq (intern lang) org= -latex-minted-langs)) lang)` in org-latex-src-block to respect minted's con= vention of putting all language names in lowercase. > Patches: diff --git a/lisp/ox-latex.el b/lisp/ox-latex.el index 59e6e83..013c731 100644 --- a/lisp/ox-latex.el +++ b/lisp/ox-latex.el @@ -1474,9 +1474,9 @@ contextual information." ;; Use minted package. ((eq org-latex-listings 'minted) (let* ((org-lang (org-element-property :language inline-src-block)) - (mint-lang (or (cadr (assq (intern org-lang) + (mint-lang (downcase (or (cadr (assq (intern org-lang) org-latex-minted-langs)) - org-lang)) + org-lang))) (options (org-latex--make-option-string org-latex-minted-options))) (concat (format "\\mint%s{%s}" @@ -2116,7 +2116,7 @@ contextual information." ("firstnumber" ,(number-to-string (1+ num-start)))) org-latex-minted-options))) ;; Language. - (or (cadr (assq (intern lang) org-latex-minted-langs)) lan= g) + (downcase (or (cadr (assq (intern lang) org-latex-minted-langs)) lang)) ;; Source code. (let* ((code-info (org-export-unravel-code src-block)) (max-width > 2) Add a key binding C-c C-v k for org-babel-remove result in ob-keys.el.= (Discussed on list but I can't find the reference) diff --git a/lisp/ob-core.el b/lisp/ob-core.el index e8943c6..c73c42b 100644 --- a/lisp/ob-core.el +++ b/lisp/ob-core.el @@ -2166,6 +2166,15 @@ code ---- the results are extracted in the syntax of the source (goto-char location) (forward-line 1) (delete-region start (org-babel-result-end)))))) +(defun org-babel-remove-result-one-or-many (x) + "Remove the result of the current source block. +If called with a prefix argument, remove all result blocks +in the buffer." + (interactive "P") + (if x + (org-babel-map-src-blocks nil (org-babel-remove-result)) + (org-babel-remove-result))) + (defun org-babel-result-end () "Return the point at the end of the current set of results." (save-excursion diff --git a/lisp/ob-keys.el b/lisp/ob-keys.el index 90b5196..dc1f437 100644 --- a/lisp/ob-keys.el +++ b/lisp/ob-keys.el @@ -89,6 +89,7 @@ functions which are assigned key bindings, and see ("h" . org-babel-describe-bindings) ("\C-x" . org-babel-do-key-sequence-in-edit-buffer) ("x" . org-babel-do-key-sequence-in-edit-buffer) + ("k" . org-babel-remove-result-one-or-many) ("\C-\M-h" . org-babel-mark-block)) "Alist of key bindings and interactive Babel functions. This list associates interactive Babel functions > > I actually wrap it so C-u C-c C-v k calls > > (org-babel-map-src-blocks nil (org-babel-remove-result)) > >> >> Thanks, >> >> -- >> Bastien >> >>