summaryrefslogtreecommitdiff
path: root/rhautoimport-tr
diff options
context:
space:
mode:
Diffstat (limited to 'rhautoimport-tr')
-rwxr-xr-xrhautoimport-tr6
1 files changed, 4 insertions, 2 deletions
diff --git a/rhautoimport-tr b/rhautoimport-tr
index c604f9d..488c5ed 100755
--- a/rhautoimport-tr
+++ b/rhautoimport-tr
@@ -38,6 +38,7 @@ my $RSS_URL = "http://cba.fro.at/series/tierrechtsradio/feed?c=Kfs2IoV2Wmd";
$XML::Feed::MULTIPLE_ENCLOSURES=1;
my $RD_GROUP = "tierrecht";
my $PV_ID = '506';
+my $LAST_RUN = 0;
my @today = Date::Calc::Standard_to_Business(Date::Calc::Today());
if($today[2] == 5) {
@@ -46,7 +47,8 @@ if($today[2] == 5) {
}
if($#ARGV >= 0 && $ARGV[0] eq 'last') {
- print "!!!This is the last attempt, there won't be a retry on error!!!\n"
+ print "!!!This is the last attempt, there won't be a retry on error!!!\n";
+ $LAST_RUN = 1;
}
@@ -128,7 +130,7 @@ for my $entry ($feed->entries) {
}
if($uri eq "") {
print "No Entry found from $bd - ";
- if($#ARGV >= 0 && $ARGV[0] eq 'last') {
+ if($LAST_RUN) {
print "giving up, manual import necessary!!!\n";
} else {
print "will retry later\n";