diff --git a/scripts/rss/syncrss.pl b/scripts/rss/syncrss.pl new file mode 100755 index 0000000000..169682c954 --- /dev/null +++ b/scripts/rss/syncrss.pl @@ -0,0 +1,23 @@ +#!/usr/local/bin/perl + +my $home = shift; + +$home or die "Usage: $0 \n"; +chdir($home); + +my $hash = { + 'freeswitch.rss' => 'http://www.freeswitch.org/xml.php' + }; + + +foreach (keys %{$hash}) { + my ($dl) = $hash->{$_} =~ /\/([^\/]+)$/; + + my $cmd = "rm -f $_ $dl ; wget $hash->{$_}"; + if ($dl ne $_) { + $cmd .= "; /bin/mv $dl $_"; + } + $cmd .= "\n"; + print $cmd; + system($cmd); +}