Get a list of packages with no dependences in FreeBSD
This Perl script makes a list of packages in FreeBSD which have no dependences.
#!/home/ben/software/install/bin/perl use warnings; use strict; use utf8; use FindBin '$Bin'; my @pkgs = `pkg info`; for (@pkgs) { my $name = $_; $name =~ s/^(\S+)\s+.*$/$1/g; my $r = `pkg info -r $name`; if ($r =~ /:.*$/) { print "$r\n"; } }
Copyright © Ben Bullock 2009-2024. All
rights reserved.
For comments, questions, and corrections, please email
Ben Bullock
(benkasminbullock@gmail.com).
/
Privacy /
Disclaimer