and we fix a one liner
This commit is contained in:
parent
9c5b0fdb64
commit
aa85fb75cf
1 changed files with 5 additions and 2 deletions
|
@ -32,7 +32,7 @@ fi
|
||||||
|
|
||||||
DELTA=`echo ${CURDATE}-${LASTRUN} | bc`
|
DELTA=`echo ${CURDATE}-${LASTRUN} | bc`
|
||||||
|
|
||||||
/path/to/last-sync -d ${DELTA} -q
|
${LAST_SYNC} -d ${DELTA} -q
|
||||||
|
|
||||||
if [ "$?" -eq "0" ]; then
|
if [ "$?" -eq "0" ]; then
|
||||||
# EPEL
|
# EPEL
|
||||||
|
@ -42,6 +42,9 @@ else
|
||||||
logger -p local0.notice -t rsync_epel "No change found. Not syncing"
|
logger -p local0.notice -t rsync_epel "No change found. Not syncing"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#######
|
||||||
|
####### CODE REUSE ALERT. THIS NEEDS TO BE A SUBROUTINE YOU SILLY
|
||||||
|
|
||||||
## Do the FEDORA download if we have had a sync since the last update.
|
## Do the FEDORA download if we have had a sync since the last update.
|
||||||
CURDATE=`date +%s`
|
CURDATE=`date +%s`
|
||||||
if [[ -s ${DATE_FED} ]]; then
|
if [[ -s ${DATE_FED} ]]; then
|
||||||
|
@ -52,7 +55,7 @@ fi
|
||||||
|
|
||||||
DELTA=`echo ${CURDATE}-${LASTRUN} | bc`
|
DELTA=`echo ${CURDATE}-${LASTRUN} | bc`
|
||||||
|
|
||||||
/path/to/last-sync -d ${DELTA} -q
|
${LAST_SYNC} -d ${DELTA} -q
|
||||||
|
|
||||||
if [ "$?" -eq "0" ]; then
|
if [ "$?" -eq "0" ]; then
|
||||||
# Enchilada
|
# Enchilada
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue