* [PATCH] [Babel] Add line number to "Processing code block..." message
@ 2013-11-07 15:31 Sebastien Vauban
2013-11-07 21:13 ` Bastien
2013-11-11 16:35 ` Eric Schulte
0 siblings, 2 replies; 9+ messages in thread
From: Sebastien Vauban @ 2013-11-07 15:31 UTC (permalink / raw)
To: emacs-orgmode-mXXj517/zsQ
Hello,
Here is a small patch to improve the messages displayed by Org Babel when
processing code blocks: now, you get the line number added to the output, so
that you can easily find afterward which block had problems, if such things
were reported in the *Messages* buffer.
Best regards,
Seb
From 9e8b74d881575318ff480f084ac10aea82696904 Mon Sep 17 00:00:00 2001
From: Sebastien Vauban <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
Date: Thu, 7 Nov 2013 16:24:53 +0100
Subject: [PATCH] Improve "Processing Org code block" message
* ob-exp.el (org-babel-exp-src-block): Improve message by adding line number.
---
lisp/ob-exp.el | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/lisp/ob-exp.el b/lisp/ob-exp.el
index c8479e3..3874338 100644
--- a/lisp/ob-exp.el
+++ b/lisp/ob-exp.el
@@ -110,12 +110,14 @@ none ---- do not display either code or results upon export
Assume point is at the beginning of block's starting line."
(interactive)
- (unless noninteractive (message "org-babel-exp processing..."))
(save-excursion
(let* ((info (org-babel-get-src-block-info 'light))
+ (line (org-current-line))
(lang (nth 0 info))
(raw-params (nth 2 info)) hash)
;; bail if we couldn't get any info from the block
+ (unless noninteractive
+ (message "Processing %s code block at line %d..." lang line))
(when info
;; if we're actually going to need the parameters
(when (member (cdr (assoc :exports (nth 2 info))) '("both" "results"))
--
1.7.9
--
Sebastien Vauban
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-07 15:31 [PATCH] [Babel] Add line number to "Processing code block..." message Sebastien Vauban
@ 2013-11-07 21:13 ` Bastien
2013-11-07 22:57 ` Sebastien Vauban
2013-11-11 16:35 ` Eric Schulte
1 sibling, 1 reply; 9+ messages in thread
From: Bastien @ 2013-11-07 21:13 UTC (permalink / raw)
To: Sebastien Vauban; +Cc: public-emacs-orgmode-mXXj517/zsQ
Hi Sébastien,
"Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
writes:
> Here is a small patch to improve the messages displayed by Org Babel when
> processing code blocks: now, you get the line number added to the output, so
> that you can easily find afterward which block had problems, if such things
> were reported in the *Messages* buffer.
(I'll let Eric decide on this one.)
PS: Don't forget to add TINYCHANGE at the end of your patches in such
cases.
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-07 21:13 ` Bastien
@ 2013-11-07 22:57 ` Sebastien Vauban
2013-11-08 7:23 ` Bastien
0 siblings, 1 reply; 9+ messages in thread
From: Sebastien Vauban @ 2013-11-07 22:57 UTC (permalink / raw)
To: emacs-orgmode-mXXj517/zsQ
Hi Bastien,
Bastien wrote:
> "Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org> writes:
>
> PS: Don't forget to add TINYCHANGE at the end of your patches in such
> cases.
I thought that the rule was:
Add TINYCHANGE if less than 20 (trivial) lines; otherwise, you need to
assign copyright to the FSF -- and, *if you signed the FSF papers, you
don't need anymore to add TINYCHANGE, whichever the length of the change.*
Is this wrong now?
Best regards,
Seb
--
Sebastien Vauban
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-07 22:57 ` Sebastien Vauban
@ 2013-11-08 7:23 ` Bastien
2013-11-08 9:07 ` Sebastien Vauban
0 siblings, 1 reply; 9+ messages in thread
From: Bastien @ 2013-11-08 7:23 UTC (permalink / raw)
To: Sebastien Vauban; +Cc: public-emacs-orgmode-mXXj517/zsQ
Hi Sébastien,
"Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
writes:
> I thought that the rule was:
>
> Add TINYCHANGE if less than 20 (trivial) lines; otherwise, you need to
> assign copyright to the FSF -- and, *if you signed the FSF papers, you
> don't need anymore to add TINYCHANGE, whichever the length of the change.*
>
> Is this wrong now?
No, that's correct, but I forgot you signed the FSF papers as you
don't appear on http://orgmode.org/worg/org-contribute.html -- can
you put your name there?
Thanks!
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-08 7:23 ` Bastien
@ 2013-11-08 9:07 ` Sebastien Vauban
2013-11-08 9:10 ` Bastien
0 siblings, 1 reply; 9+ messages in thread
From: Sebastien Vauban @ 2013-11-08 9:07 UTC (permalink / raw)
To: emacs-orgmode-mXXj517/zsQ
Hi Bastien,
Bastien wrote:
> "Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org> writes:
>
>> I thought that the rule was:
>>
>> Add TINYCHANGE if less than 20 (trivial) lines; otherwise, you need to
>> assign copyright to the FSF -- and, *if you signed the FSF papers, you
>> don't need anymore to add TINYCHANGE, whichever the length of the change.*
>>
>> Is this wrong now?
>
> No, that's correct, but I forgot you signed the FSF papers as you
> don't appear on http://orgmode.org/worg/org-contribute.html -- can
> you put your name there?
It's already in there (since some years): I'm #113 in your list of current
contributors.
Best regards,
Seb
--
Sebastien Vauban
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-08 9:07 ` Sebastien Vauban
@ 2013-11-08 9:10 ` Bastien
0 siblings, 0 replies; 9+ messages in thread
From: Bastien @ 2013-11-08 9:10 UTC (permalink / raw)
To: Sebastien Vauban; +Cc: public-emacs-orgmode-mXXj517/zsQ
"Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
writes:
> It's already in there (since some years): I'm #113 in your list of current
> contributors.
Yes, indeed, sorry! (Was looking for "Séb", not "Seb"...)
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-07 15:31 [PATCH] [Babel] Add line number to "Processing code block..." message Sebastien Vauban
2013-11-07 21:13 ` Bastien
@ 2013-11-11 16:35 ` Eric Schulte
2013-11-11 16:58 ` Bastien
2013-11-13 8:39 ` Sebastien Vauban
1 sibling, 2 replies; 9+ messages in thread
From: Eric Schulte @ 2013-11-11 16:35 UTC (permalink / raw)
To: Sebastien Vauban; +Cc: emacs-orgmode
Hi Seb,
Thanks for this patch, I've applied it and then tweaked the wording of
the message.
Best,
"Sebastien Vauban" <sva-news@mygooglest.com> writes:
> Hello,
>
> Here is a small patch to improve the messages displayed by Org Babel when
> processing code blocks: now, you get the line number added to the output, so
> that you can easily find afterward which block had problems, if such things
> were reported in the *Messages* buffer.
>
> Best regards,
> Seb
>
> From 9e8b74d881575318ff480f084ac10aea82696904 Mon Sep 17 00:00:00 2001
> From: Sebastien Vauban <sva-news@mygooglest.com>
> Date: Thu, 7 Nov 2013 16:24:53 +0100
> Subject: [PATCH] Improve "Processing Org code block" message
>
> * ob-exp.el (org-babel-exp-src-block): Improve message by adding line number.
>
> ---
> lisp/ob-exp.el | 4 +++-
> 1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/lisp/ob-exp.el b/lisp/ob-exp.el
> index c8479e3..3874338 100644
> --- a/lisp/ob-exp.el
> +++ b/lisp/ob-exp.el
> @@ -110,12 +110,14 @@ none ---- do not display either code or results upon export
>
> Assume point is at the beginning of block's starting line."
> (interactive)
> - (unless noninteractive (message "org-babel-exp processing..."))
> (save-excursion
> (let* ((info (org-babel-get-src-block-info 'light))
> + (line (org-current-line))
> (lang (nth 0 info))
> (raw-params (nth 2 info)) hash)
> ;; bail if we couldn't get any info from the block
> + (unless noninteractive
> + (message "Processing %s code block at line %d..." lang line))
> (when info
> ;; if we're actually going to need the parameters
> (when (member (cdr (assoc :exports (nth 2 info))) '("both" "results"))
> --
> 1.7.9
--
Eric Schulte
https://cs.unm.edu/~eschulte
PGP: 0x614CA05D
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-11 16:35 ` Eric Schulte
@ 2013-11-11 16:58 ` Bastien
2013-11-13 8:39 ` Sebastien Vauban
1 sibling, 0 replies; 9+ messages in thread
From: Bastien @ 2013-11-11 16:58 UTC (permalink / raw)
To: Eric Schulte; +Cc: Sebastien Vauban, emacs-orgmode
Eric Schulte <schulte.eric@gmail.com> writes:
> Thanks for this patch, I've applied it and then tweaked the wording of
> the message.
Thanks!
--
Bastien
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] [Babel] Add line number to "Processing code block..." message
2013-11-11 16:35 ` Eric Schulte
2013-11-11 16:58 ` Bastien
@ 2013-11-13 8:39 ` Sebastien Vauban
1 sibling, 0 replies; 9+ messages in thread
From: Sebastien Vauban @ 2013-11-13 8:39 UTC (permalink / raw)
To: emacs-orgmode-mXXj517/zsQ
Hello Eric,
Eric Schulte wrote:
> "Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org> writes:
>> Here is a small patch to improve the messages displayed by Org Babel when
>> processing code blocks: now, you get the line number added to the output, so
>> that you can easily find afterward which block had problems, if such things
>> were reported in the *Messages* buffer.
>>
>> - (message "org-babel-exp processing..."))
>> ...
>> + (message "Processing %s code block at line %d..." lang line))
>
> Thanks for this patch, I've applied it and then tweaked the wording of the
> message.
I thought my wording was more clear from a user perspective, but I don't mind
with yours, and I'm happy that line has been added. Much clearer to use the
information from the *Messages* buffer.
Best regards,
Seb
--
Sebastien Vauban
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2013-11-13 8:39 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-11-07 15:31 [PATCH] [Babel] Add line number to "Processing code block..." message Sebastien Vauban
2013-11-07 21:13 ` Bastien
2013-11-07 22:57 ` Sebastien Vauban
2013-11-08 7:23 ` Bastien
2013-11-08 9:07 ` Sebastien Vauban
2013-11-08 9:10 ` Bastien
2013-11-11 16:35 ` Eric Schulte
2013-11-11 16:58 ` Bastien
2013-11-13 8:39 ` Sebastien Vauban
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).