unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* ido to match user logins.
@ 2006-10-15 12:57 Michaël Cadilhac
  2006-10-15 20:32 ` Kim F. Storm
  0 siblings, 1 reply; 2+ messages in thread
From: Michaël Cadilhac @ 2006-10-15 12:57 UTC (permalink / raw)



[-- Attachment #1.1.1: Type: text/plain, Size: 242 bytes --]


Ido has a little flaw in the matching of the paths like `~whatever_t/'
or `~user-name$/'. It would be great if that regexp can be enriched.

Proposition attached, the regexp is inspired from the « useradd » binary
of a Gentoo Linux.


[-- Attachment #1.1.2: ido.patch --]
[-- Type: text/x-patch, Size: 1330 bytes --]

Index: lisp/ido.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/ido.el,v
retrieving revision 1.108
diff -c -r1.108 ido.el
*** lisp/ido.el	6 Oct 2006 22:54:36 -0000	1.108
--- lisp/ido.el	15 Oct 2006 12:52:55 -0000
***************
*** 4168,4174 ****
  	    (setq refresh t))
  	   ((string-equal contents "./")
  	    (setq refresh t))
! 	   ((string-match "\\`~[a-zA-Z0-9]+/\\'" contents)
  	    (ido-trace "new home" contents)
  	    (ido-set-current-home contents)
  	    (setq refresh t))
--- 4168,4174 ----
  	    (setq refresh t))
  	   ((string-equal contents "./")
  	    (setq refresh t))
! 	   ((string-match "\\`~[-_a-zA-Z0-9]+[$]?/\\'" contents)
  	    (ido-trace "new home" contents)
  	    (ido-set-current-home contents)
  	    (setq refresh t))
Index: lisp/ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.10192
diff -c -0 -r1.10192 ChangeLog
*** lisp/ChangeLog	14 Oct 2006 23:25:43 -0000	1.10192
--- lisp/ChangeLog	15 Oct 2006 12:53:08 -0000
***************
*** 0 ****
--- 1,4 ----
+ 2006-10-15  Michaël Cadilhac  <michael.cadilhac@lrde.org>
+ 
+ 	* ido.el (ido-exhibit): Enrich the regexp that matches user logins.
+ 

[-- Attachment #1.1.3: Type: text/plain, Size: 391 bytes --]


-- 
/!\ My mail address changed, please update your files accordingly.
 |      Michaël `Micha' Cadilhac   |  Would someone please DTRT with this,  |
 |         Epita/LRDE Promo 2007   |        then ACK?                       |
 |  http://michael.cadilhac.name   |          -- Richard Stallman           |
 `--  -   JID: micha@amessage.be --'                                   -  --'

[-- Attachment #1.2: Type: application/pgp-signature, Size: 188 bytes --]

[-- Attachment #2: Type: text/plain, Size: 142 bytes --]

_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel

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

* Re: ido to match user logins.
  2006-10-15 12:57 ido to match user logins Michaël Cadilhac
@ 2006-10-15 20:32 ` Kim F. Storm
  0 siblings, 0 replies; 2+ messages in thread
From: Kim F. Storm @ 2006-10-15 20:32 UTC (permalink / raw)
  Cc: emacs-devel

michael@cadilhac.name (Michaël Cadilhac) writes:

> Ido has a little flaw in the matching of the paths like `~whatever_t/'
> or `~user-name$/'. It would be great if that regexp can be enriched.

Thanks for the improvement.  Committed.

-- 
Kim F. Storm <storm@cua.dk> http://www.cua.dk

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

end of thread, other threads:[~2006-10-15 20:32 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-10-15 12:57 ido to match user logins Michaël Cadilhac
2006-10-15 20:32 ` Kim F. Storm

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