Complete-Host
view release on metacpan - search on metacpan
view release on metacpan or search on metacpan
lib/Complete/Host.pm view on Meta::CPAN
for my $prog ("/sbin/ifconfig") {
next unless -x $prog;
my @lines = IPC::System::Options::readpipe(
{lang=>"C"}, "$prog -a");
next if $?;
for my $line (@lines) {
if ($line =~ /^\s*inet addr:(\S+)/) {
log_trace("[comphost] Adding %s", $1) if $COMPLETE_HOST_TRACE;
$hosts{$1}++;
}
if ($line =~ m!^\s*inet6 addr:\s*(\S+?)(?:/\d+)?(?=\s)!) {
log_trace("[comphost] Adding %s", $1) if $COMPLETE_HOST_TRACE;
$hosts{$1}++;
}
}
last IFCONFIG;
}
}
# from SSH known_hosts
{
view all matches for this distributionview release on metacpan - search on metacpan
( run in 1.039 second using v1.00-cache-2.02-grep-82fe00e-cpan-b63e86051f13 )