aboutsummaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2015-09-03 18:11:07 +0100
committerMatthew Somerville <matthew@mysociety.org>2015-09-04 06:25:52 -0700
commitf2c893ed4a773d3658b5645ef4329689a8b908f1 (patch)
tree159c3fbcd4860067fa6e275714ad12c7d79232e6 /bin
parentc507dbefe9048aca52386027976607a549391513 (diff)
Improve gettext-extract to work without fuss.
Use bundled carton to install required module separately, using a minimal cpanfile (and Debian squeeze generated snapshot). Fixes #1202.
Diffstat (limited to 'bin')
-rwxr-xr-xbin/gettext-extract5
1 files changed, 5 insertions, 0 deletions
diff --git a/bin/gettext-extract b/bin/gettext-extract
index c1f3d384e..ca37e9d6d 100755
--- a/bin/gettext-extract
+++ b/bin/gettext-extract
@@ -9,6 +9,11 @@
cd "$(dirname $(readlink -f $BASH_SOURCE))/.."
+# Install required code if needed
+vendor/bin/carton install --path local-gettext --cpanfile locale/cpanfile --deployment
+export PATH="local-gettext/bin:$PATH"
+export PERL5LIB="local-gettext/lib/perl5:local/lib/perl5"
+
# File to write to, clear it to start with
PO=locale/FixMyStreet.po
rm -f $PO