annotate po/Makefile @ 155:497ed1991e85

Modify project selection The new project selection has two advantages: 1. It's possible to create and run e.g. projects a and aa Therefore it is possible to create a hirarchy again. 2. When inserting the project key only letters for valid projects are accepted. E.g. two projects exists aa and ab. In that case it is not possible to insert ac. Only a will be shown in the footer.
author Björn Ricks <bjoern.ricks@intevation.de>
date Thu, 06 Dec 2012 13:14:22 +0100
parents e6f81aa329b1
children
rev   line source
36
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
1 all:
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
2 @echo 'Usage:'
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
3 @echo ' make pot create getan.pot'
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
4 @echo ' make merge merge a new getan.pot with the *.po files'
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
5 @echo ' make mo create the mo files'
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
6 @echo ' make stat print statistics about the translation status'
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
7
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
8 MO_DIR = ../share/locale
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
9 DOMAIN = getan
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
10
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
11 pot:
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
12 pygettext -o $(DOMAIN).pot ../getan/*.py
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
13
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
14 merge:
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
15 for po in *.po; do \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
16 lingua=`basename $$po .po`; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
17 mv $$lingua.po $$lingua.old.po; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
18 if msgmerge -o $$lingua.po $$lingua.old.po $(DOMAIN).pot; then\
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
19 rm $$lingua.old.po; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
20 else \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
21 rm -f $$lingua.po; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
22 mv $$lingua.old.po $$lingua.po; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
23 fi \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
24 done
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
25
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
26
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
27 mo:
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
28 for po in *.po; do\
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
29 lingua=`basename $$po .po`; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
30 install -d $(MO_DIR)/$$lingua/LC_MESSAGES/ ; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
31 echo -n $$po": "; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
32 msgfmt --statistics \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
33 -o $(MO_DIR)/$$lingua/LC_MESSAGES/$(DOMAIN).mo $$po ;\
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
34 done
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
35
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
36
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
37 stat:
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
38 @for po in *.po; do\
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
39 echo -n $$po": "; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
40 msgfmt --statistics -o /dev/null $$po 2>&1 \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
41 | sed -e 's/ \(messages*\|translations*\)//g' -e 's/\.$$//' ; \
e6f81aa329b1 Introduced i18n support; german and english translation available.
Ingo Weinzierl <ingo_weinzierl@web.de>
parents:
diff changeset
42 done
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)