File: update_rss.pl

package info (click to toggle)
libxml-rss-perl 1.48-1
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 756 kB
  • ctags: 231
  • sloc: perl: 6,888; xml: 378; makefile: 2
file content (20 lines) | stat: -rw-r--r-- 428 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/usr/bin/perl
# update_rss.pl
# Adds a new item to the RSS file
use strict;
use warnings;

use XML::RSS;

die "Syntax: update_rss.pl source.rdf destination.rdf\n\n"
	unless @ARGV == 2;

my $rss = XML::RSS->new;
$rss->parsefile(shift);

$rss->add_item(title => "MpegTV Player (mtv) 1.0.9.7",
               link  => "http://freshmeat.net/news/1999/06/21/930003958.html",
	       mode => 'insert'
	       );

$rss->save(shift);