[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
ido to match user logins.
From: |
Michaël Cadilhac |
Subject: |
ido to match user logins. |
Date: |
Sun, 15 Oct 2006 14:57:01 +0200 |
User-agent: |
Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux) |
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.
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 <address@hidden>
+
+ * ido.el (ido-exhibit): Enrich the regexp that matches user logins.
+
--
/!\ 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: address@hidden --' - --'
pgpiMGfcVgwnn.pgp
Description: PGP signature
- ido to match user logins.,
Michaël Cadilhac <=