Suzanne Hillman <[EMAIL PROTECTED]> writes:
>How does one determine the name of the package one would need for a
>specific file/command/binary/etc under Debian (without using the
>search tool on their site)?
The information is in the Contents file, e.g.
/debian/dists/potato/Contents-i386.gz
I found myself searching it often enough that I wrote a script to do
it (see attached).
For example:
vanzandt:/tmp$ deblocate bin/xfig
usr/X11R6/bin/xfig graphics/xfig
usr/bin/xfig-pdf-viewer graphics/xfig-doc
usr/bin/xfig-www-browser graphics/xfig-doc
...so xfig is in the "xfig" package, in section "graphics".
- Jim Van Zandt
#!/bin/sh -e
#
# deblocate - find a file in the Debian distribution by searching Contents
#
path=/debian
# Contents entries do not have a leading /
PATTERN=`echo $1 | sed 's,^/,,'`
if [ -n "$PATTERN" ]; then
arch=`dpkg --print-architecture`
file=Contents-$arch.gz
for d in stable frozen unstable; do
try=$path/dists/$d/$file
if [ -f $try ]; then CONT=$try; fi
done
zcat $CONT | egrep $PATTERN
else
echo "deblocate - find a file in the Debian distribution by searching Contents"
echo "usage: deblocate <regex>"
exit 1
fi
**********************************************************
To unsubscribe from this list, send mail to
[EMAIL PROTECTED] with the following text in the
*body* (*not* the subject line) of the letter:
unsubscribe gnhlug
**********************************************************