Package: locate Version: 4.2.33-1 Severity: normal
The manual says: For each given pattern, locate searches one or more databases of file names and dis- plays the file names that contain the pattern. Patterns can contain shell-style metacharacters: `*', `?', and `[]'. The metacharacters do not treat `/' or `.' specially. Therefore, a pattern `foo*bar' can match a file name that contains `foo3/bar', and a pattern `*duck*' can match a file name that contains `lake/.ducky'. Note the use of the word "contain", several times. This seems to mean that the pattern can be any part of the file name. In the example given in the manual, I would expect locate "foo*bar" to match files like: /usr/share/doc/package/examples/foo3/bar But in practice, it will never match any file at all (as far as I can tell). This is what I get: griffon:~$ sudo updatedb griffon:~$ locate bash\*completion griffon:~$ locate \*bash\*completion /etc/bash_completion /usr/share/doc/bash/BUGS.bash_completion Without a leading * the pattern simply never matches anything at all. What's even more confusing is that a pattern WITHOUT a * in it works the way I would expect (and the way the manual describes): griffon:~$ locate bash_completion /etc/bash_completion /etc/bash_completion.d /etc/bash_completion.d/debconf /etc/bash_completion.d/m-a /etc/bash_completion.d/make_kpkg /etc/bash_completion.d/pon /etc/bash_completion.d/subversion /usr/share/doc/bash/BUGS.bash_completion /usr/share/doc/bash/changelog.bash_completion.gz /usr/share/doc/bash/README.bash_completion.gz Under no circumstances would I expect bash_completion to match more files than bash*completion does. The * version should be a superset of the _ version. -- System Information: Debian Release: lenny/sid APT prefers unstable APT policy: (500, 'unstable') Architecture: i386 (i686) Kernel: Linux 2.6.24-1-686 (SMP w/1 CPU core) Locale: LANG=en_US.ISO8859-1, LC_CTYPE=en_US.ISO8859-1 (charmap=ISO-8859-1) Shell: /bin/sh linked to /bin/bash Versions of packages locate depends on: ii findutils 4.2.33-1 utilities for finding files--find, ii libc6 2.7-8 GNU C Library: Shared libraries locate recommends no packages. -- debconf-show failed -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]