[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#24606: 25.1.50; (thing-at-point 'filename) doesn't recognize names w
From: |
Tino Calancha |
Subject: |
bug#24606: 25.1.50; (thing-at-point 'filename) doesn't recognize names with @ |
Date: |
Tue, 4 Oct 2016 16:18:48 +0900 (JST) |
User-agent: |
Alpine 2.20 (DEB 67 2015-01-07) |
X-Debbugs-CC: Emanuel Berg <embe8573@student.uu.se>
X-Debbugs-CC: tino.calancha@gmail.com
Problem reported by Emanuel Berg in:
https://lists.gnu.org/archive/html/emacs-devel/2016-07/msg01219.html
emacs -Q:
(let ((str "/lib/systemd/system/getty@.service")
res)
(with-temp-buffer
(insert str)
(let ((thing-at-point-file-name-chars "-@~/[:alnum:]_.${}#%,:"))
(push `(thing-at-point-patched . ,(thing-at-point 'filename)) res))
(push `(thing-at-point . ,(thing-at-point 'filename)) res)) res)
=> ((thing-at-point . ".service") (thing-at-point-patched .
"/lib/systemd/system/getty@.service"))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
From 3a4a8c7245a4b4713a92cd77e75a375cf366a825 Mon Sep 17 00:00:00 2001
From: Emanuel Berg <embe8573@student.uu.se>
Date: Tue, 4 Oct 2016 16:10:44 +0900
Subject: [PATCH] thing-at-point: Add @ as a valid character for file names
Reported in:
https://lists.gnu.org/archive/html/emacs-devel/2016-07/msg01219.html
* lisp/thingatpt.el (thing-at-point-file-name-chars): Add @ (Bug#24606).
---
lisp/thingatpt.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lisp/thingatpt.el b/lisp/thingatpt.el
index 9920fa0..704dc69 100644
--- a/lisp/thingatpt.el
+++ b/lisp/thingatpt.el
@@ -244,7 +244,7 @@ thing-at-point-bounds-of-list-at-point
;; Filenames
-(defvar thing-at-point-file-name-chars "-~/[:alnum:]_.${}#%,:"
+(defvar thing-at-point-file-name-chars "-@~/[:alnum:]_.${}#%,:"
"Characters allowable in filenames.")
(put 'filename 'end-op
--
2.9.3
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
In GNU Emacs 25.1.50.1 (x86_64-pc-linux-gnu, GTK+ Version 3.22.0)
of 2016-10-04 built on calancha-pc
Repository revision: 74b4f13842f3119f98797ea76d9be42457b330e1
- bug#24606: 25.1.50; (thing-at-point 'filename) doesn't recognize names with @,
Tino Calancha <=