File: demopipeprogram.pl.sample

package info (click to toggle)
ndpmon 1.4.0-2.1
  • links: PTS
  • area: main
  • in suites: buster, stretch
  • size: 4,292 kB
  • ctags: 455
  • sloc: ansic: 5,250; sh: 207; xml: 177; perl: 128; makefile: 105; python: 56
file content (17 lines) | stat: -rwxr-xr-x 301 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/perl

my $i=0;
open DATA, ">>/usr/local/ndpmon/test.txt" or die "Cannot open /usr/local/ndpmon/test.txt for writing\n";

print DATA "-----\n";
while (<STDIN>) {
  chomp;
  if ($_ ne "") {
    $i++;
    print DATA "$i: $_\n";
#    print "$i: $_\n";
  }
}
print DATA "-----\n\n";

close DATA;