Page 1 of 1
depfinder
Posted: 06 Sep 2013, 19:00
by Jack
I found this packages "depfinder" it finds dep fast. What I like for it to do is do a directory at one time and not a fine at a time. Can someone tell me how to write a script or write it for me?
Jack
Re: depfinder
Posted: 06 Sep 2013, 20:13
by francois
Very interesting package, jack. Thanks a lot.
depfinder would have been developped by pagan, one of the administrator of salix os. See the link, citation:
http://sourceforge.net/projects/depfinder/
depfinder reports the dependencies of Slackware packages. It is faster than previous tools used for the same purpose and even has support for utilizing multiple CPUs/cores
Other info on depfinder:
http://depfinder.sourceforge.net/
Re: depfinder
Posted: 06 Sep 2013, 20:44
by Jack
How hard would it be to write a script to go with depfinder to find all the dependencies in a directory?
Re: depfinder
Posted: 06 Sep 2013, 23:33
by brokenman
Useful little tool.
Copy the following into a script called getdeps.sh
#!/bin/bash
if [ `find $1 -type f|egrep ".txz|.tgz"|wc -l` -eq 0 ]; then
echo "No packages found!!"
exit
fi
for a in `find $1 -type f|egrep ".tgz|.txz"`; do
depfinder $a
done
Imagine I have some packages in /tmp/myfolder. I would put this script in /usr/bin and then simply type:
getdeps.sh /tmp/myfolder
Keep in mind you can type getde[TAB] ## [TAB] here means just type the first few letters and then hit the TAB key to autocomplete the script name.
Re: depfinder
Posted: 07 Sep 2013, 01:50
by Jack
I can find grep but not egrep can anyone help?
Re: depfinder
Posted: 07 Sep 2013, 03:37
by francois
Please jack, let's put in a little autonomy:
google egrep:
http://www.cs.columbia.edu/~tal/3261/fa ... torial.htm
Re: depfinder
Posted: 07 Sep 2013, 13:57
by brokenman
egrep is the same as grep -e
This is a switch to tell 'grep' that you will feed it a regex pattern. Normally you can only grep one thing. For example to find two types of word documents on a disk
find /mnt/sda2/User/john/Documents -type f | egrep ".doc|.docx"
| | | |
| | | |
Search The path of type 'file' regex pattern
grep --help