summaryrefslogtreecommitdiff
path: root/libre/icedove-l10n/check.sh
blob: 4c92ca12ed36a9606220002bc5d9e639ab574f0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/bash
# helper script to check the local language list against upstream

# extract language list from pkgbuild
bash -c "source PKGBUILD && printf '%s\n' \"\${_languages[@]}\" | cut -d ' ' -f1 | sort" \
  > icedove-l10n.local

# load language list from upstream
url="$(bash -c "source PKGBUILD && echo \"\$_pkgurl\"")/"
curl -sL $url | \
  grep '\.xpi' | cut -d'"' -f2 | rev | cut -d'/' -f1 | rev | cut -d'.' -f1 | sort\
  > icedove-l10n.remote

diff -rupN icedove-l10n.local icedove-l10n.remote
rm -f icedove-l10n.{local,remote}