summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorTilman Blumenbach2017-02-12 17:42:35 +0100
committerTilman Blumenbach2017-02-12 17:42:35 +0100
commit5e5c4b1c77edd5fd9b2ac04ac6c0a54497d607ab (patch)
treee0fda5ecbb64253e81473b0a6aaf54dea27c6d41
parent0f435fcd0c31b953d8a265829c9a90d920d67a8a (diff)
downloadaur-5e5c4b1c77edd5fd9b2ac04ac6c0a54497d607ab.tar.gz
pkgver() must not produce any superfluous output.
Usually, makepkg just takes the stuff that pkgver() prints to stdout, so we can output any log messages to stderr. However, when makepkg is in logging mode ("makepkg -L ..."), then it merges stdout and stderr together and uses the result as the pkgver (I'm sure that's a bug!), which breaks the build horribly due to us logging things. So do not log anything at all now.
-rw-r--r--.SRCINFO4
-rw-r--r--PKGBUILD11
2 files changed, 6 insertions, 9 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 2019cec50ff8..982ae73b3f4a 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = fortune-mod-bofh-excuses
pkgdesc = BOFH excuses fortune cookie files
- pkgver = 20121125.190600
- pkgrel = 5
+ pkgver = 20151113.024512
+ pkgrel = 1
url = http://www.cs.wisc.edu/~ballard/bofh/
arch = any
groups = fortune-mods
diff --git a/PKGBUILD b/PKGBUILD
index 87da450138f6..43e331a15202 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,8 +2,8 @@
# Contributor: lanrat
pkgname='fortune-mod-bofh-excuses'
-pkgver=20121125.190600
-pkgrel=5
+pkgver=20151113.024512
+pkgrel=1
pkgdesc='BOFH excuses fortune cookie files'
arch=('any')
url='http://www.cs.wisc.edu/~ballard/bofh/'
@@ -19,16 +19,13 @@ pkgver()
# Make a HTTP HEAD request and use the Last-Modified header of the data file
# to generate the pkgver. Thanks to djmattyg007 for the idea (and the hint that
# the Debian package I used previously is somewhat outdated by now :-)!
-
- msg2 "Determining data file's time of last modification..."
- local lastmod=$(curl -fL -I "${_dlurl}" | tac | sed -n '/^Last-modified:[[:space:]]*/I { s///p; q }')
+ local lastmod=$(curl -sS -fL -I "${_dlurl}" | tac | sed -n '/^Last-modified:[[:space:]]*/I { s///p; q }')
if [ -z "$lastmod" ]; then
- warning "Could not determine time of last modification, not updating pkgver."
return 1
fi
- date -ud "${lastmod}" '+%Y%m%d.%H%M%S' || { warning "Failed to generate pkgver, it will not be updated."; return 1; }
+ date -ud "${lastmod}" '+%Y%m%d.%H%M%S'
}
prepare()