emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nicolas Goaziou <mail@nicolasgoaziou.fr>
To: Anthony Carrico <acarrico@memebeam.org>
Cc: emacs-orgmode@gnu.org
Subject: Re: ISSUE: Unable to resolve link (html export)
Date: Sun, 16 Aug 2020 11:18:13 +0200	[thread overview]
Message-ID: <87sgcnosoa.fsf@nicolasgoaziou.fr> (raw)
In-Reply-To: <16807dee-efc9-1bd4-0137-529b7339681e@memebeam.org> (Anthony Carrico's message of "Thu, 6 Aug 2020 14:24:46 -0400")

Hello,

Anthony Carrico <acarrico@memebeam.org> writes:

> * Steps to reproduce:
>
> 1. Create a file called test.org:
>
> #+TITLE: test.org
>
> 2. Create a file called test2.org:
>
> #+TITLE: test2.org
> [[file:test.org::+TITLE: test][test]]
>
> 3. Export C-c C-e h H
>
> * Expected result:
>
> An html buffer
>
> * Actual result:
>
> Unable to resolve link: "No match for fuzzy expression: +TITLE: test"
>
> * Additional data
>
> The link was created by going to the first line of test.org and hitting 
> C-c l, then the second line of test2.org and hitting C-c C-l.
>
> * Work around
>
> It seems like changing the link to:
>
> [[file:test.org::#+TITLE: test][test]]
>
> allows the export to succeed. On the other hand, the original link works 
> fine internally. This leads me to suspect that export is using different 
> code to follow links, but also that the insert link code is buggy, 
> skipping the pound symbol.

The pound character has a special meaning in links. It denotes custom
IDs. Here,

  [[file:test.org::#+TITLE: test]]

means you're looking for a headline with the CUSTOM_ID property set to
"+TITLE: test" in the file "test.org"

Therefore, it is automatically removed in another context, e.g., in text
search.

However, the export process doesn't resolve text searches. 

If you want to link to a specific part of the text, you can use
a target.

Regards,
-- 
Nicolas Goaziou


      reply	other threads:[~2020-08-16  9:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-06 18:24 ISSUE: Unable to resolve link (html export) Anthony Carrico
2020-08-16  9:18 ` Nicolas Goaziou [this message]

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=87sgcnosoa.fsf@nicolasgoaziou.fr \
    --to=mail@nicolasgoaziou.fr \
    --cc=acarrico@memebeam.org \
    --cc=emacs-orgmode@gnu.org \
    /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).