diff options
author | Tilman Blumenbach | 2015-08-13 21:08:26 +0200 |
---|---|---|
committer | Tilman Blumenbach | 2015-08-13 21:08:26 +0200 |
commit | f7bbbe6ab2ebb8bdf4667d969e3d6293c2736632 (patch) | |
tree | ca4832f997a7810ebc5ea87aad9a945993d89b28 | |
parent | 92a783e9511a0a70c5d5d213c04a74451dcec7d4 (diff) | |
download | aur-f7bbbe6ab2ebb8bdf4667d969e3d6293c2736632.tar.gz |
Only redownload data file if necessary.
-rw-r--r-- | PKGBUILD | 11 |
1 files changed, 10 insertions, 1 deletions
@@ -33,8 +33,17 @@ pkgver() prepare() { + # Okay, this may not be the ideal place to download the data file, + # but we DO want to update it on every run -- if we let makepkg + # download it for us, it will not be re-downloaded if it already + # exists locally (and that would be bad since the data file could + # have been updated on the server since the last download). + # + # Instead, we instruct curl to only download the file if it is + # newer than the local copy (if it exists). + msg2 "Downloading data file..." - curl -fL -o "${srcdir}/bofh-excuses.raw" "${_dlurl}" + curl -fL -Ro "${srcdir}/bofh-excuses.raw" -z "${srcdir}/bofh-excuses.raw" "${_dlurl}" } build() |