On Tue, 2003-12-30 at 16:24, Tom Diehl wrote: > Thanks for the info but I should have given some more details as to what > I was actually trying to do. I knew I could do this in the shell but I am > playing with perl and so far I have not found a way to make it do what I want. > I am trying to do something like the following: I haven't figured out anything better using just rpm but for perl; 1 of the 1000's of possibilities: $path = "/etc/auto.* /tmp/*"; @files = glob($path); # expand shell escapes $path = join(' ', @files); # put together so we can # just call rpm once open(CKFILE, "rpm -qf $path |") || die "Can not run rpm"; foreach $file (@files) { # assume that rpm returns the answer in the same order # as its parameters. $_ = <CKFILE>; # use $_ since it is default chomp; # for commands like this if (/^file /) { # and this print "Process line -->$file<--\n"; } else { print "File >>$file<< is owned by >>$_<<, Skipping\n"; } } close CKFILE; -- enjoy scott _______________________________________________ Rpm-list mailing list Rpm-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/rpm-list