File: tv_validate_file.PL

package info (click to toggle)
xmltv 1.4.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 9,396 kB
  • sloc: perl: 37,189; xml: 5,017; sh: 153; makefile: 18
file content (18 lines) | stat: -rw-r--r-- 615 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# Generate tv_validate_file from tv_validate_file.in.
#
# The second argument is the share directory for the final
# installation.

use IO::File;
my $out = shift @ARGV; die "no output file given" if not defined $out;
my $share_dir = shift @ARGV;
die "no final share/ location given" if not defined $share_dir;
my $in = 'tools/tv_validate_file.in';
my $in_fh = new IO::File "< $in" or die "cannot read $in: $!";
my $out_fh = new IO::File "> $out" or die "cannot write to $out: $!";
while (<$in_fh>) {
    print $out_fh $_;
}
close $out_fh or die "cannot close $out: $!";
close $in_fh or die "cannot close $in: $!";