emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Incompatible changes regarding link
@ 2019-12-06 15:35 Kiwon Um
  2019-12-06 20:33 ` Nicolas Goaziou
  0 siblings, 1 reply; 5+ messages in thread
From: Kiwon Um @ 2019-12-06 15:35 UTC (permalink / raw)
  To: emacs-orgmode

Hello,

I just noticed that the recent updates regarding the bracket link escaping syntax seem to have an issue.

Does anybody happen to know how to put a pair of [] around a link without using "zero width space" or something similar?
For example,
[[[https://somewhere-to-url][My Link]]] does not succeed in exporting to HTML showing "Unable to resolve link: "[https://somewhere-to-url"".
[[https://somewhere-to-url][[My Link]]] is not properly exported; the closing bracket "]" is not included in the exported link.

Thank you!

Best regards,
Kiwon

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Incompatible changes regarding link
  2019-12-06 15:35 Incompatible changes regarding link Kiwon Um
@ 2019-12-06 20:33 ` Nicolas Goaziou
  2019-12-06 20:55   ` Kiwon Um
  0 siblings, 1 reply; 5+ messages in thread
From: Nicolas Goaziou @ 2019-12-06 20:33 UTC (permalink / raw)
  To: Kiwon Um; +Cc: emacs-orgmode

Hello,

Kiwon Um <um.kiwon@gmail.com> writes:

> I just noticed that the recent updates regarding the bracket link escaping syntax seem to have an issue.
>
> Does anybody happen to know how to put a pair of [] around a link without using "zero width space" or something similar?
> For example,
> [[[https://somewhere-to-url][My Link]]] does not succeed in exporting to HTML showing "Unable to resolve link: "[https://somewhere-to-url"".

I don't see any issue here. The "zero width space" is exactly for that
situation. 

But, honestly, the fact that it worked differently in the past is the
real issue. The current interpretation is correct.

> [[https://somewhere-to-url][[My Link]]] is not properly exported; the
> closing bracket "]" is not included in the exported link.

This looks like a different problem. If you want to include the
brackets, you need to escape them, as explained in the ORG-NEWS
document, or in the manual:

  [[https://somewhere-to-url][\[My Link\]]]

Regards,

-- 
Nicolas Goaziou

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Incompatible changes regarding link
  2019-12-06 20:33 ` Nicolas Goaziou
@ 2019-12-06 20:55   ` Kiwon Um
  2019-12-06 21:10     ` Nicolas Goaziou
  0 siblings, 1 reply; 5+ messages in thread
From: Kiwon Um @ 2019-12-06 20:55 UTC (permalink / raw)
  To: emacs-orgmode

Hello,

Thank you for the reply.

On Fri, Dec 6, 2019 at 9:33 PM Nicolas Goaziou <mail@nicolasgoaziou.fr> wrote:
> Kiwon Um <um.kiwon@gmail.com> writes:
>
> > I just noticed that the recent updates regarding the bracket link escaping syntax seem to have an issue.
> >
> > Does anybody happen to know how to put a pair of [] around a link without using "zero width space" or something similar?
> > For example,
> > [[[https://somewhere-to-url][My Link]]] does not succeed in exporting to HTML showing "Unable to resolve link: "[https://somewhere-to-url"".
>
> I don't see any issue here. The "zero width space" is exactly for that
> situation.
> But, honestly, the fact that it worked differently in the past is the
> real issue. The current interpretation is correct.

I didn't know what the issue in the past interpretation was, but I am
just not sure whether it's a good idea to enforce that we must use
such a special character, which we cannot directly see from the
editor.

> > [[https://somewhere-to-url][[My Link]]] is not properly exported; the
> > closing bracket "]" is not included in the exported link.
>
> This looks like a different problem. If you want to include the
> brackets, you need to escape them, as explained in the ORG-NEWS
> document, or in the manual:
>
>   [[https://somewhere-to-url][\[My Link\]]]

Unfortunately, this doesn't work either.
[[https://www.youtube.com/][\[You Tube\]]] is exported as <a
href="https://www.youtube.com/">\[You Tube\</a>]

Regards,
Kiwon

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Incompatible changes regarding link
  2019-12-06 20:55   ` Kiwon Um
@ 2019-12-06 21:10     ` Nicolas Goaziou
  2019-12-06 21:45       ` Kiwon Um
  0 siblings, 1 reply; 5+ messages in thread
From: Nicolas Goaziou @ 2019-12-06 21:10 UTC (permalink / raw)
  To: Kiwon Um; +Cc: emacs-orgmode

Kiwon Um <um.kiwon@gmail.com> writes:

> I didn't know what the issue in the past interpretation was, but I am
> just not sure whether it's a good idea to enforce that we must use
> such a special character, which we cannot directly see from the
> editor.

This is because you are using an ambiguous construct. There are things
you cannot do in Org (e.g., starting a line with "|" and expect it to be
something else than a table), yet, Org provides a syntax to work around
the problem. I agree this is not perfect.

>> > [[https://somewhere-to-url][[My Link]]] is not properly exported; the
>> > closing bracket "]" is not included in the exported link.
>>
>> This looks like a different problem. If you want to include the
>> brackets, you need to escape them, as explained in the ORG-NEWS
>> document, or in the manual:
>>
>>   [[https://somewhere-to-url][\[My Link\]]]
>
> Unfortunately, this doesn't work either.
> [[https://www.youtube.com/][\[You Tube\]]] is exported as <a
> href="https://www.youtube.com/">\[You Tube\</a>]

Indeed! I forgot about that: the escaping mechanism is for the link
part. For the description part, you have to use a zero width space, too.
Note that `org-insert-link' (C-c C-l) does that automatically.

IIRC, square brackets were forbidden in descriptions (and changed into
curly brackets automatically) before that change.

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Incompatible changes regarding link
  2019-12-06 21:10     ` Nicolas Goaziou
@ 2019-12-06 21:45       ` Kiwon Um
  0 siblings, 0 replies; 5+ messages in thread
From: Kiwon Um @ 2019-12-06 21:45 UTC (permalink / raw)
  To: emacs-orgmode

On Fri, Dec 6, 2019 at 10:10 PM Nicolas Goaziou <mail@nicolasgoaziou.fr> wrote:
>
> Kiwon Um <um.kiwon@gmail.com> writes:
>
> > I didn't know what the issue in the past interpretation was, but I am
> > just not sure whether it's a good idea to enforce that we must use
> > such a special character, which we cannot directly see from the
> > editor.
>
> This is because you are using an ambiguous construct. There are things
> you cannot do in Org (e.g., starting a line with "|" and expect it to be
> something else than a table), yet, Org provides a syntax to work around
> the problem. I agree this is not perfect.

I understand Org-mode has its syntax. I am not saying Org-mode should
be able to do everything we want. As you already agreed, I'm just not
sure whether it's the best. In my opinion, one of the great advantages
of Org-mode is that we can do a lot of things with plain texts, and
here I am just little bit unhappy with using hidden characters to
escape something, particularly in a plane text file.

> > Unfortunately, this doesn't work either.
> > [[https://www.youtube.com/][\[You Tube\]]] is exported as <a
> > href="https://www.youtube.com/">\[You Tube\</a>]
>
> Indeed! I forgot about that: the escaping mechanism is for the link
> part. For the description part, you have to use a zero width space, too.
> Note that `org-insert-link' (C-c C-l) does that automatically.
>
> IIRC, square brackets were forbidden in descriptions (and changed into
> curly brackets automatically) before that change.

Right, that seems to be the only option for now. I may use zero width
spaces or other parentheses around links.
Thank you for your time again.

Best,
Kiwon

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-12-06 21:45 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-12-06 15:35 Incompatible changes regarding link Kiwon Um
2019-12-06 20:33 ` Nicolas Goaziou
2019-12-06 20:55   ` Kiwon Um
2019-12-06 21:10     ` Nicolas Goaziou
2019-12-06 21:45       ` Kiwon Um

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).