Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the 'Look inside pkg files without expanding them' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Look inside pkg files without expanding them
Authored by: gatorparrots on May 01, '03 11:12:46PM
These types of scripts have been written before:
StaticInnerClass/testuser published his whichbom script here:
for file in `ls /Library/Receipts/` 
  exists=`lsbom -p sfMUG /Library/Receipts/${file}/Contents/ 2> /dev/null | egrep "$1" ` 
  if [ -n "$exists" ]; then 
    echo "Found in ${file}:" 
    echo "$exists" 
    echo "" 
Usage: to find the parent package of a file:
whichbom `which command`
And the inimitable Gary Kerbaugh has his pkggrep script here:

"It's been way to long since I've done a shameless ad. Did you use my pkggrep script? If not, you might want to check it out. For the most, searching a single package receipt is a one-liner and searching all of them, a short loop. However, the creator of Pacifist suggested a number of options that might be useful. Thus, it's a little bloated but allows you customize your search quite a bit. Anyway, if you don't have it, you should at least look at it; any suggestions would be greatly appreciated!"

[ Reply to This | # ]