Help for this page

Select Code to Download


  1. or download this
    my $verbose = 1;
    my $r_cat = 'ssh %s cat "%s" |'; # host, file
    ...
        chomp;
        print "I read line '$_'\n";
    };
    
  2. or download this
    my $verbose = 1;
    my $r_grep = 'ssh %s grep "%s" "%s" |'; # host, re, file
    ...
        die "Weird line <$_>" unless /foo|bar/;
        print "Read line [$_]\n";
    };