unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Yuri Khan <yuri.v.khan@gmail.com>
To: Amos Bird <amosbird@gmail.com>
Cc: Emacs developers <emacs-devel@gnu.org>
Subject: Re: goto-address-at-point doesn't get the right url when there is a trailing ')'
Date: Wed, 14 Jun 2017 22:01:44 +0700	[thread overview]
Message-ID: <CAP_d_8WThsKckRA5qZP6dam=+v2y3bf3qOCnwmU1uk_DpNzuFw@mail.gmail.com> (raw)
In-Reply-To: <877f0e5169.fsf@gmail.com>

On Wed, Jun 14, 2017 at 5:11 PM, Amos Bird <amosbird@gmail.com> wrote:

> When doing  (goto-address-at-point) at parenthesis surrounded urls like this
> (https://github.com/nikomatsakis/rayon/issues/231) in any prog mode (c, java, python ...)
>
> it will grab the trailing ')' thus ends up with opening a wrong url.

> Could you tell me a workaround for this?

Don’t do that, then?

A closing parenthesis is a valid URL character. Any heuristic that
fixes your problem will break legal, standard-conforming URLs, such as
this:

    https://en.wikipedia.org/wiki/Dunnet_(video_game)

If you want to enclose a URL in parentheses, put a pair of angle
brackets <> around it first:

    (<https://github.com/nikomatsakis/rayon/issues/231>)

Angle brackets are not valid URL characters and are expicitly
recommended as delimiters around URLs by RFC 2396 § 2.4.3 and RFC 3986
Appendix C. Also, it is a Markdown construct for URLs displayed as-is.



  reply	other threads:[~2017-06-14 15:01 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <878tkv3rii.fsf@gmail.com>
2017-06-14 10:11 ` goto-address-at-point doesn't get the right url when there is a trailing ')' Amos Bird
2017-06-14 15:01   ` Yuri Khan [this message]
2017-06-14 15:05     ` Amos Bird
2017-06-15  9:01     ` Philipp Stephani
2017-06-15  9:04       ` Amos Bird
2017-06-15  9:51         ` Philipp Stephani
2017-06-15 13:49           ` Amos Bird
2017-06-16 16:27             ` Philipp Stephani

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.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to='CAP_d_8WThsKckRA5qZP6dam=+v2y3bf3qOCnwmU1uk_DpNzuFw@mail.gmail.com' \
    --to=yuri.v.khan@gmail.com \
    --cc=amosbird@gmail.com \
    --cc=emacs-devel@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.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).