summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorMike Kazantsev2021-12-08 20:28:13 +0500
committerfraggod@malediction2021-12-08 20:28:13 +0500
commitf8a8673d6c5ddd10e8594f8673d59b006ffdadb9 (patch)
tree5ac347afa571ec9b8bf003808fe8406aa5501f5f /PKGBUILD
parenta66775f13d309d1ca5bfb66f9165b86875479bce (diff)
downloadaur-f8a8673d6c5ddd10e8594f8673d59b006ffdadb9.tar.gz
Check parsed version, reword WARNING about api_id to be less dire
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD3
1 files changed, 2 insertions, 1 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 7de4c97dfa1c..694487a3c3f2 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -15,6 +15,7 @@ sha256sums=(SKIP)
pkgver() {
cd $pkgname
ver=$(awk '/^\s*set\(VERSION / {sub(")","",$2); print $2}' CMakeLists.txt)
+ [[ -n "$ver" ]] || { echo >&2 "ERROR: Failed to parse version from CMakeLists.txt"; exit 1; }
printf "%s.r%s.%s" "$ver" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
@@ -29,7 +30,7 @@ build() {
else
echo >&2 "WARNING: --------------------"
echo >&2 "WARNING: tdlib-purple will be built with default/testing API_ID and API_HASH credentials."
- echo >&2 "WARNING: This will likely cause 400 (API_ID_PUBLISHED_FLOOD) error on login when using it."
+ echo >&2 "WARNING: This can cause 400 (API_ID_PUBLISHED_FLOOD) error on login when using it."
echo >&2 "WARNING: Set/export TD_API_ID and TD_API_HASH env vars to use custom (working) values there."
echo >&2 "WARNING: Check https://core.telegram.org/api/obtaining_api_id URL for how to easily get those."
echo >&2 "WARNING: --------------------"