File: gen_words_template.sh

package info (click to toggle)
qabcs 1.0.2-7
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 44,724 kB
  • sloc: cpp: 2,226; sh: 2,001; xml: 25; makefile: 5
file content (24 lines) | stat: -rwxr-xr-x 593 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#/bin/sh
# Author: Alexey Loginov
# Licence: GPLv3+
# Description: get words to be translated by transifex based on picture names (JAVA UTF8 format)

pushd ..

rm -f langs/qabcs_en.properties

for dir in `dir abcs/all/pics`
do
  for filename in `dir -1 abcs/all/pics/$dir|cut -d "." -f 1`
  do
    word=`echo $filename|sed "s|_| |g"`
    echo "$filename=$word" >> langs/qabcs_en.properties
  done
done

cat langs/qabcs_en.properties|sort -u > langs/qabcs_en_tmp.properties
mv -f langs/qabcs_en_tmp.properties langs/qabcs_en.properties

popd

echo "File langs/qabcs_en.properties was written!"