emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: "Eric Schulte" <schulte.eric@gmail.com>
To: "Sébastien Vauban" <wxhgmqzgwmuf@spammotel.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Re: [Babel] Small problem with tangling
Date: Thu, 14 Oct 2010 17:17:40 -0600	[thread overview]
Message-ID: <87mxqg8iuj.fsf@gmail.com> (raw)
In-Reply-To: <804ocolsx4.fsf@mundaneum.com> ("Sébastien Vauban"'s message of "Thu, 14 Oct 2010 17:01:43 +0200")

Hi Seb,

I fully agree with your point, I believe I've just pushed up a fix for
this issue.  This commit includes a short function with a long name
`ob-tangle/no-excessive-id-insertion-on-tangle' in test-ob-tangle.el.

Best -- Eric

Sébastien Vauban <wxhgmqzgwmuf@spammotel.com> writes:

> Hi Eric,
>
> "Eric Schulte" wrote:
>> Sébastien Vauban <wxhgmqzgwmuf@spammotel.com> writes:
>>> "Eric Schulte" wrote:
>>>>> [...] empty first line that's always inserted at the beginning of the
>>>>> file. What should I do to get rid of that first *empty* line?
>>>>
>>>> The following inhibits the insertion of blank lines on tangling.
>>>>
>>>>   (setq org-babel-tangle-pad-newline nil)
>>>
>>> Of course, that does work as expected. Thanks for the tip.
>>>
>>> Another side-question about a little annoyance: when having just one src
>>> block to tangle in a big file, and when tangling it, Org(-Babel?) does
>>> first add IDs everywhere in my file, one for every section.
>>>
>>> Could we get rid of that? I don't even understand why one would be needed,
>>> though I could easily "accept" (;-)) to see an ID created in the sections
>>> containing elements to tangle.
>>
>> This is caused by the tangling code calling `org-store-link' on every code
>> block, which is useful because we sometimes want to store links in the
>> tangled code for jumping back from the code to the relevant place in the
>> original org-mode file.
>
> I understand the need for creating links automatically to sections which host
> code blocks.
>
> However, I don't understand that tangling the *only* code block I have in an
> entire Org file does add ID in *every* section. Shouldn't it be limited to
> sections hosting code blocks in general (in particular, IMHO, it should even
> be limited to the only sections that contain blocks to *tangle*)?
>
>
>> `org-store-link' is called interactively, and it will insert ID values
>> according to the value of `org-link-to-org-use-id', which defaults to
>> `create-if-interactive-and-no-custom-id'. I suppose you could change the
>> value of this variable which should avoid the insertion of custom IDs.
>
> I have the same value as you.
>
> I could try every of them, but -- from the doc -- I don't see any better
> option for this. I want IDs to be created!  It's only I'd like them to be
> created for sections that need it...
>
> Best regards,
>   Seb

  reply	other threads:[~2010-10-14 23:17 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-13 14:15 [Babel] Small problem with tangling Sébastien Vauban
2010-10-13 15:26 ` Eric Schulte
2010-10-14  7:37   ` Sébastien Vauban
2010-10-14 13:53     ` Eric Schulte
2010-10-14 15:01       ` Sébastien Vauban
2010-10-14 23:17         ` Eric Schulte [this message]
2010-10-15 12:40           ` Sébastien Vauban
2010-10-14 12:28   ` [Babel] Small problem with... previewing Sébastien Vauban
2010-10-14 13:53     ` Dan Davison
2010-10-14 14:15     ` Eric Schulte
2010-10-14 14:55       ` Sébastien Vauban
2010-10-14 15:04         ` Dan Davison
2010-10-14 23:03         ` Eric Schulte

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87mxqg8iuj.fsf@gmail.com \
    --to=schulte.eric@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=wxhgmqzgwmuf@spammotel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).