all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Visuwesh <visuweshm@gmail.com>
Cc: philipk@posteo.net, 67600@debbugs.gnu.org
Subject: bug#67600: [PATCH] Add dashes to 'thing-at-point-email-regexp'
Date: Tue, 12 Dec 2023 15:08:41 +0200	[thread overview]
Message-ID: <83ttontvom.fsf@gnu.org> (raw)
In-Reply-To: <87edfrtwxg.fsf@gmail.com> (message from Visuwesh on Tue, 12 Dec 2023 18:11:47 +0530)

> From: Visuwesh <visuweshm@gmail.com>
> Cc: philipk@posteo.net,  67600@debbugs.gnu.org
> Date: Tue, 12 Dec 2023 18:11:47 +0530
> 
> [Tuesday December 12, 2023] Eli Zaretskii wrote:
> 
> >> I am running Emacs with the same change before Philip created this bug
> >> report and so far I haven't had false positives for email addresses
> >> because files with a @ in its name is rare.  In practise, I think this
> >> patch is harmless in that regard.
> >
> > Remote files that have user@host in their names do have that
> > character.
> 
> AFAIU, user cannot have slashes in them as per the POSIX standards [1]
> and likewise with hostname so remote files should not pose a problem.
> Of course this assumes that you're only looking at methods like ssh,
> doas, sudo, etc.  It seems like tramp disallows slashes in user and host
> anyway, try:
> 
>     (file-remote-p "/ssh:userwith/@host:/") ;; => nil
>     (file-remote-p "/ssh:userwith@host/:/") ;; => nil
>     (file-remote-p "/ssh:userwith@host:/") ;; => /ssh:userwith@host:

Why are you talking about slashes in user and host names?  There are
slashes in remote file names outside of those two.  Are you saying
that slashes in thing-at-point-email-regexp will only ever match if
they are in the user or host names?  That's not what I see:

  (string-match "<?[-+_~a-zA-Z0-9/][-+_.~:a-zA-Z0-9/]*@[-a-zA-Z0-9]+[-.a-zA-Z0-9]*>?" 
    "/ssh:userwith@host:/what/ever/it/can/be")
      => 0





  reply	other threads:[~2023-12-12 13:08 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-03 12:52 bug#67600: [PATCH] Add dashes to 'thing-at-point-email-regexp' Philip Kaludercic
2023-12-03 13:14 ` Eli Zaretskii
2023-12-12  7:21   ` Philip Kaludercic
2023-12-12 12:06     ` Eli Zaretskii
2023-12-12 12:21       ` Visuwesh
2023-12-12 12:27         ` Eli Zaretskii
2023-12-12 12:41           ` Visuwesh
2023-12-12 13:08             ` Eli Zaretskii [this message]
2023-12-12 13:23               ` Visuwesh
2023-12-12 13:35                 ` Eli Zaretskii
2023-12-12 14:25                   ` Visuwesh
2023-12-16 10:41       ` Philip Kaludercic
2023-12-16 13:38         ` Eli Zaretskii
2023-12-16 14:50           ` Philip Kaludercic
2023-12-16 14:59             ` Eli Zaretskii
2023-12-17 12:11               ` Philip Kaludercic

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

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

  git send-email \
    --in-reply-to=83ttontvom.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=67600@debbugs.gnu.org \
    --cc=philipk@posteo.net \
    --cc=visuweshm@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 external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.