In 'dlocate' version 0.96.1:
% man dlocate | grep -n -C 2 "dlocate -l '^.. libc5'"
51- Extended regular expression are allowed. For example,
52-
53: dlocate -l '^.. libc5'
54-
55- will list all the package names starting with `libc5'.
Copy and paste fails:
% dlocate -l '^.. libc5' ; echo $?
1
Is it a space or a tab before "libc5"? Answer:
% man dlocate | grep "dlocate -l '^.. libc5'" | hexdump -C
00000000 20 20 20 20 20 20 20 20 20 20 20 20 20 20 64 6c |
dl|
00000010 6f 63 61 74 65 20 2d 6c 20 27 5e 2e 2e 20 6c 69 |ocate -l
'^.. li|
00000020 62 63 35 27 0a |bc5'.|
00000025
A space. Trial & error proves that a tab works, but 'grep' lacks a tab
escape code, (that is a '\t'). So for clarity, and reliable copy & paste:
ht=`echo -e '\011'` # codify horizontal tab
dlocate -l "^..${ht}libc5"
Patch attached.
Ho ho hope this helps...
--- dlocate.1 2008-06-27 06:11:40.000000000 -0400
+++ /tmp/dlocate.1 2008-12-24 02:20:45.000000000 -0500
@@ -61,7 +61,9 @@
Extended regular expression are allowed. For example,
-\fBdlocate \-l '^.. libc5'\fP
+\fBht=`echo \-e '\\011'` # codify horizontal tab
+.br
+dlocate \-l "^..${ht}libc5"\fP
will list all the package names starting with `libc5'.