root/misc/bonjourfind

Revision 1959 (checked in by miyagawa, 13 years ago)

use Pod::Usage

  • Property svn:executable set to *
Line 
1 #!/usr/bin/perl
2 use strict;
3 use warnings;
4 use Net::Rendezvous;
5 use Pod::Usage;
6
7 my $proto = shift @ARGV || pod2usage(1);
8 my $res = Net::Rendezvous->new($proto);
9 $res->discover;
10
11 for my $entry ($res->entries) {
12     printf "%s %s:%s\n", $entry->name, $entry->address, $entry->port;
13 }
14
15 __END__
16
17 =head1 NAME
18
19 bonjourfind - Find Bonjour entries
20
21 =head1 SYNOPSIS
22
23   bonjourfind [protocol]
24
25 =cut
Note: See TracBrowser for help on using the browser.