summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2014-08-02 20:31:00 +0200
committerFlorian Pritz <bluewind@xinu.at>2014-08-02 20:31:00 +0200
commit280294bb1690a98349f17a2798aee0ef06abbcce (patch)
tree594bab2e7aae79b522bd061e7579e5bd53a1d7b3
parent465769cd00069d8c0b0af73bc8072012f242d5a9 (diff)
downloadbin-280294bb1690a98349f17a2798aee0ef06abbcce.tar.gz
bin-280294bb1690a98349f17a2798aee0ef06abbcce.tar.xz
rename syncrepo to fix name clashes with installed one
Signed-off-by: Florian Pritz <bluewind@xinu.at>
-rwxr-xr-xsyncrepo.sh (renamed from syncrepo)3
1 files changed, 2 insertions, 1 deletions
diff --git a/syncrepo b/syncrepo.sh
index dd72a94..25f8223 100755
--- a/syncrepo
+++ b/syncrepo.sh
@@ -16,7 +16,8 @@ lastupdate_url="http://mirror.pkgbuild.com/lastupdate"
exec 9>"${lock}"
flock -n 9 || exit
-if diff -b <(curl -s "$lastupdate_url") "$target/lastupdate" >/dev/null; then
+# if we are called without a tty (cronjob) only run when there are changes
+if ! tty -s && diff -b <(curl -s "$lastupdate_url") "$target/lastupdate" >/dev/null; then
exit 0
fi