summaryrefslogtreecommitdiff
path: root/libre
diff options
context:
space:
mode:
Diffstat (limited to 'libre')
-rw-r--r--libre/iceape-l10n/check.sh18
-rw-r--r--libre/icecat-l10n/check.sh18
-rw-r--r--libre/icedove-l10n/PKGBUILD4
-rw-r--r--libre/icedove-l10n/check.sh15
-rw-r--r--libre/iceweasel-l10n/check.sh13
5 files changed, 55 insertions, 13 deletions
diff --git a/libre/iceape-l10n/check.sh b/libre/iceape-l10n/check.sh
new file mode 100644
index 000000000..6aa005b2d
--- /dev/null
+++ b/libre/iceape-l10n/check.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+# helper script to check the local language list against upstream
+
+# extract pkgbase from pkgbuild
+pkgbase="$(bash -c "source PKGBUILD && echo \"\$pkgbase\"")"
+
+# extract language list from pkgbuild
+bash -c "source PKGBUILD && printf '%s\n' \"\${_languages[@]}\" | cut -d ' ' -f1 | sort" \
+ > $pkgbase-l10n.local
+
+# load language list from upstream
+url="$(bash -c "source PKGBUILD && echo \"\$_url\"")/"
+curl -sL $url | \
+ grep '\.xpi' | cut -d'"' -f2 | rev | cut -d'/' -f1 | cut -d'.' -f3 | rev | sort\
+ > $pkgbase-l10n.remote
+
+diff -rupN $pkgbase-l10n.local $pkgbase-l10n.remote
+rm -f $pkgbase-l10n.{local,remote}
diff --git a/libre/icecat-l10n/check.sh b/libre/icecat-l10n/check.sh
new file mode 100644
index 000000000..99f792c3d
--- /dev/null
+++ b/libre/icecat-l10n/check.sh
@@ -0,0 +1,18 @@
+#!/bin/bash
+# helper script to check the local language list against upstream
+
+# extract pkgbase from pkgbuild
+pkgbase="$(bash -c "source PKGBUILD && echo \"\$pkgbase\"")"
+
+# extract language list from pkgbuild
+bash -c "source PKGBUILD && printf '%s\n' \"\${_languages[@]}\" | cut -d ' ' -f1 | sort" \
+ > $pkgbase-l10n.local
+
+# load language list from upstream
+url="$(bash -c "source PKGBUILD && echo \"\$_url\"")/"
+curl -sL $url | \
+ grep '\.xpi"' | cut -d'"' -f8 | rev | cut -d'/' -f1 | cut -d'.' -f3 | rev | sort \
+ > $pkgbase-l10n.remote
+
+diff -rupN $pkgbase-l10n.local $pkgbase-l10n.remote
+rm -f $pkgbase-l10n.{local,remote}
diff --git a/libre/icedove-l10n/PKGBUILD b/libre/icedove-l10n/PKGBUILD
index e6b72d773..948f76c58 100644
--- a/libre/icedove-l10n/PKGBUILD
+++ b/libre/icedove-l10n/PKGBUILD
@@ -85,7 +85,7 @@ _languages=(
pkgname=()
source=('brand.dtd' 'brand.properties' 'region.properties')
-_pkgurl=https://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/$pkgver/linux-i686/xpi
+_url=https://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/$pkgver/linux-i686/xpi
_calurl=https://ftp.mozilla.org/pub/calendar/lightning/candidates/$_calver-candidates/build1/linux-i686
for _lang in "${_languages[@]}"; do
@@ -93,7 +93,7 @@ for _lang in "${_languages[@]}"; do
_pkgname=$pkgbase-${_locale,,}
pkgname+=($_pkgname)
- source+=("$pkgbase-$pkgver-$_locale.xpi::$_pkgurl/$_locale.xpi"
+ source+=("$pkgbase-$pkgver-$_locale.xpi::$_url/$_locale.xpi"
"$_calbase-l10n-$_calver-$_locale.xpi::$_calurl/lightning-$_calver.$_locale.linux-i686.xpi")
eval "package_$_pkgname() {
_package $_lang
diff --git a/libre/icedove-l10n/check.sh b/libre/icedove-l10n/check.sh
index 4c92ca12e..ea37f4c4f 100644
--- a/libre/icedove-l10n/check.sh
+++ b/libre/icedove-l10n/check.sh
@@ -1,15 +1,18 @@
#!/bin/bash
# helper script to check the local language list against upstream
+# extract pkgbase from pkgbuild
+pkgbase="$(bash -c "source PKGBUILD && echo \"\$pkgbase\"")"
+
# extract language list from pkgbuild
bash -c "source PKGBUILD && printf '%s\n' \"\${_languages[@]}\" | cut -d ' ' -f1 | sort" \
- > icedove-l10n.local
+ > $pkgbase-l10n.local
# load language list from upstream
-url="$(bash -c "source PKGBUILD && echo \"\$_pkgurl\"")/"
+url="$(bash -c "source PKGBUILD && echo \"\$_url\"")/"
curl -sL $url | \
- grep '\.xpi' | cut -d'"' -f2 | rev | cut -d'/' -f1 | rev | cut -d'.' -f1 | sort\
- > icedove-l10n.remote
+ grep '\.xpi' | cut -d'"' -f2 | rev | cut -d'/' -f1 | cut -d'.' -f2 | rev | sort\
+ > $pkgbase-l10n.remote
-diff -rupN icedove-l10n.local icedove-l10n.remote
-rm -f icedove-l10n.{local,remote}
+diff -rupN $pkgbase-l10n.local $pkgbase-l10n.remote
+rm -f $pkgbase-l10n.{local,remote}
diff --git a/libre/iceweasel-l10n/check.sh b/libre/iceweasel-l10n/check.sh
index 63ef703b1..ea37f4c4f 100644
--- a/libre/iceweasel-l10n/check.sh
+++ b/libre/iceweasel-l10n/check.sh
@@ -1,15 +1,18 @@
#!/bin/bash
# helper script to check the local language list against upstream
+# extract pkgbase from pkgbuild
+pkgbase="$(bash -c "source PKGBUILD && echo \"\$pkgbase\"")"
+
# extract language list from pkgbuild
bash -c "source PKGBUILD && printf '%s\n' \"\${_languages[@]}\" | cut -d ' ' -f1 | sort" \
- > iceweasel-l10n.local
+ > $pkgbase-l10n.local
# load language list from upstream
url="$(bash -c "source PKGBUILD && echo \"\$_url\"")/"
curl -sL $url | \
- grep '\.xpi' | cut -d'"' -f2 | rev | cut -d'/' -f1 | rev | cut -d'.' -f1 | sort\
- > iceweasel-l10n.remote
+ grep '\.xpi' | cut -d'"' -f2 | rev | cut -d'/' -f1 | cut -d'.' -f2 | rev | sort\
+ > $pkgbase-l10n.remote
-diff -rupN iceweasel-l10n.local iceweasel-l10n.remote
-rm -f iceweasel-l10n.{local,remote}
+diff -rupN $pkgbase-l10n.local $pkgbase-l10n.remote
+rm -f $pkgbase-l10n.{local,remote}