summarylogtreecommitdiffstats
path: root/update.sh
diff options
context:
space:
mode:
Diffstat (limited to 'update.sh')
-rwxr-xr-xupdate.sh8
1 files changed, 8 insertions, 0 deletions
diff --git a/update.sh b/update.sh
index 00896230d655..3f224f90240f 100755
--- a/update.sh
+++ b/update.sh
@@ -1,9 +1,17 @@
#!/bin/bash
+
+# ##########################
+# You can use this script
+# to update PKGBUILD version
+# ##########################
+
+
_remote=$(curl -sL https://product-details.mozilla.org/1.0/firefox_versions.json | jq -r '.FIREFOX_NIGHTLY')
_current=$(grep _version= PKGBUILD | cut -f2 -d'=')
echo "PKGBUILD: ${_current}, REMOTE: ${_remote}"
if [ "${_remote}" != "${_current}" ]; then
sed -i "s/_version=.*/_version=${_remote}/" PKGBUILD
+ sed -i "s/pkgver=.*/pkgver=${_remote}/" PKGBUILD
echo "Updated"
exit 0
fi