From: Christian Moe <mail@christianmoe.com>
To: arozbiz@gmail.com
Cc: Emacs-orgmode@gnu.org
Subject: Re: How to combine two org files that each have footnotes?
Date: Thu, 11 Feb 2021 21:05:35 +0100 [thread overview]
Message-ID: <87czx6wesw.fsf@christianmoe.com> (raw)
In-Reply-To: <CAJniy+NWTDUVFe-UvavAbAtEpcugGf4hRAzGayWn0XxqXisQHg@mail.gmail.com>
Hi,
This is actually easy because Org allows named footnotes (numbers are
really just a special case of names).
Make backup copies of your files for safety's sake, then visit file1.org
and M-% to replace all instances of "fn:" with (for example)
"fn:file1_". The footnotes will now be named fn:file1_1, fn:file1_2,
etc. At this point all your footnotes across the two documents are
already uniquely named (but you can of course also do the corresponding
thing to file2 if you like). Merge away.
Yours,
Christian
arozbiz@gmail.com writes:
> Most of my writing is academic and involves lots of footnotes. Sometimes it
> is useful to be able to combine two separate files, each of which have
> footnotes. How do I do so in a way that automatically renumbers the
> footnotes in the file that comes second?
>
> More specifically, I have file1.org and file2.org, and each of them have
> three footnotes ([fn:1], [fn:2], and [fn:3]). I want to create file3.org,
> which simply merges file1.org and file2.org, with the contents of file2.org
> coming after the contents of file1.org. The problem is that the footnote
> calls ([fn:#]) in the file2 section will end up pointing the file1
> footnotes. What I really want is to automatically renumber all the
> footnotes [fn:1]...[fn:6], but I don't know how to do this, given that org
> permits multiple footnote calls to the same footnote.
>
> Thanks,
> Alan
next prev parent reply other threads:[~2021-02-11 20:32 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-11 17:49 How to combine two org files that each have footnotes? arozbiz
2021-02-11 18:26 ` Russell Adams
2021-02-11 20:05 ` Christian Moe [this message]
2021-02-11 23:54 ` Kyle Meyer
2021-02-14 0:03 ` arozbiz
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=87czx6wesw.fsf@christianmoe.com \
--to=mail@christianmoe.com \
--cc=Emacs-orgmode@gnu.org \
--cc=arozbiz@gmail.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).