summaryrefslogtreecommitdiff
path: root/rhautoimport
diff options
context:
space:
mode:
authorChristian Pointner <equinox@helsinki.at>2016-03-13 04:08:49 (GMT)
committerChristian Pointner <equinox@helsinki.at>2016-03-13 04:08:49 (GMT)
commit4c6858a1213d0b967aa767f6aca72e37b79cee8d (patch)
treeed262cba29f3cd2a9125c9a283fa43628a5de328 /rhautoimport
parent6dbb44e71bdfb241624b0d722b78139dab98ff27 (diff)
rhautoimport launcher now passes through all but the first arguments
Diffstat (limited to 'rhautoimport')
-rwxr-xr-xrhautoimport8
1 files changed, 4 insertions, 4 deletions
diff --git a/rhautoimport b/rhautoimport
index f7c52c4..2518231 100755
--- a/rhautoimport
+++ b/rhautoimport
@@ -22,7 +22,7 @@
#
if [ -z "$1" ]; then
- echo "rhautoimport <importer> [ last ]"
+ echo "rhautoimport <importer> [ arg1 [ arg2 ] ... ]"
exit 1
fi
@@ -61,10 +61,10 @@ if [ -z "$MAIL_TO" ]; then
MAIL_TO="root"
fi
-/usr/bin/rhautoimport-$1 $2 > $LOG_FILE 2>&1
+/usr/bin/rhautoimport-$1 ${@:2} > $LOG_FILE 2>&1
case $? in
0)
- /usr/bin/mail -a "Content-Type: text/plain; charset=utf-8" -s "$TITLE - Imported Successfully" $MAIL_TO < $LOG_FILE
+ mail -a "Content-Type: text/plain; charset=utf-8" -s "$TITLE - Imported Successfully" $MAIL_TO < $LOG_FILE
;;
42)
# do nothing - the script didn't import anything but no message should be sent
@@ -75,7 +75,7 @@ case $? in
else
subject="$TITLE - Import Error - will retry"
fi
- /usr/bin/mail -a "Content-Type: text/plain; charset=utf-8" -s "$subject" $MAIL_TO < $LOG_FILE
+ mail -a "Content-Type: text/plain; charset=utf-8" -s "$subject" $MAIL_TO < $LOG_FILE
;;
esac