~twitter-scope-team/twitter-scope/trunk

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/bash
set -ex
PWD=$(pwd)
POT=twitter
POT="$POT.pot"
echo "POT will be: $POT"

JSONS="./JSONS"

# Ensure required packages are installed

dpkg -l intltool | grep intltool | grep -q ^ii

if [ $? -ne 0 ]; then
    echo "Error: You mustinstall intltool pkg in the system in which $0 executes"
    exit 1
fi

# create starting pot file
xgettext -d twitter -s ../src/twitter.go -L c++ -o twitter.pot.in.pot --keyword=Gettext --keyword=NGettext:1,2 -c
intltool-update -p -g twitter-ini

msgcat -o twitter.pot twitter-ini.pot twitter.pot.in.pot

rm twitter.pot.in.pot
rm twitter-ini.pot


sed -i 's_Project-Id-Version: PACKAGE VERSION_Project-Id-Version: Twitter Scope_g' twitter.pot


exit 0