gettext 3.0.0 → 3.0.1
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +23 -12
- data/doc/text/news.md +31 -0
- data/lib/gettext/po.rb +17 -7
- data/lib/gettext/po_entry.rb +212 -208
- data/lib/gettext/po_format.rb +28 -0
- data/lib/gettext/po_parser.rb +25 -25
- data/lib/gettext/text_domain.rb +10 -0
- data/lib/gettext/tools/msginit.rb +19 -1
- data/lib/gettext/tools/msgmerge.rb +122 -68
- data/lib/gettext/tools/task.rb +306 -87
- data/lib/gettext/tools/xgettext.rb +27 -1
- data/lib/gettext/version.rb +1 -1
- data/locale/bg/LC_MESSAGES/gettext.mo +0 -0
- data/locale/bs/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ca/LC_MESSAGES/gettext.mo +0 -0
- data/locale/cs/LC_MESSAGES/gettext.mo +0 -0
- data/locale/de/LC_MESSAGES/gettext.mo +0 -0
- data/locale/el/LC_MESSAGES/gettext.mo +0 -0
- data/locale/eo/LC_MESSAGES/gettext.mo +0 -0
- data/locale/es/LC_MESSAGES/gettext.mo +0 -0
- data/locale/et/LC_MESSAGES/gettext.mo +0 -0
- data/locale/fr/LC_MESSAGES/gettext.mo +0 -0
- data/locale/hr/LC_MESSAGES/gettext.mo +0 -0
- data/locale/hu/LC_MESSAGES/gettext.mo +0 -0
- data/locale/it/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ja/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ko/LC_MESSAGES/gettext.mo +0 -0
- data/locale/lv/LC_MESSAGES/gettext.mo +0 -0
- data/locale/nb/LC_MESSAGES/gettext.mo +0 -0
- data/locale/nl/LC_MESSAGES/gettext.mo +0 -0
- data/locale/pt_BR/LC_MESSAGES/gettext.mo +0 -0
- data/locale/ru/LC_MESSAGES/gettext.mo +0 -0
- data/locale/sr/LC_MESSAGES/gettext.mo +0 -0
- data/locale/sv/LC_MESSAGES/gettext.mo +0 -0
- data/locale/uk/LC_MESSAGES/gettext.mo +0 -0
- data/locale/vi/LC_MESSAGES/gettext.mo +0 -0
- data/locale/zh/LC_MESSAGES/gettext.mo +0 -0
- data/locale/zh_TW/LC_MESSAGES/gettext.mo +0 -0
- data/po/bg/gettext.po +370 -284
- data/po/bs/gettext.po +378 -321
- data/po/ca/gettext.po +373 -284
- data/po/cs/gettext.po +371 -313
- data/po/de/gettext.po +380 -282
- data/po/el/gettext.po +377 -277
- data/po/eo/gettext.po +373 -275
- data/po/es/gettext.po +376 -277
- data/po/et/gettext.po +374 -274
- data/po/fr/gettext.po +380 -279
- data/po/gettext.pot +102 -70
- data/po/hr/gettext.po +371 -308
- data/po/hu/gettext.po +376 -276
- data/po/it/gettext.po +362 -269
- data/po/ja/gettext.po +338 -216
- data/po/ko/gettext.po +392 -266
- data/po/lv/gettext.po +377 -310
- data/po/nb/gettext.po +377 -278
- data/po/nl/gettext.po +371 -274
- data/po/pt_BR/gettext.po +376 -277
- data/po/ru/gettext.po +380 -311
- data/po/sr/gettext.po +378 -310
- data/po/sv/gettext.po +331 -258
- data/po/uk/gettext.po +380 -311
- data/po/vi/gettext.po +374 -275
- data/po/zh/gettext.po +397 -266
- data/po/zh_TW/gettext.po +397 -266
- data/samples/cgi/README +0 -2
- data/samples/cgi/locale/bg/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/bg/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/bg/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/bg/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/bs/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/bs/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/bs/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/bs/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/ca/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/ca/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/ca/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/ca/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/cs/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/cs/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/cs/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/cs/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/de/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/de/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/de/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/de/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/el/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/el/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/el/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/el/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/eo/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/eo/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/eo/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/eo/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/es/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/es/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/es/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/es/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/fr/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/fr/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/fr/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/fr/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/hr/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/hr/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/hr/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/hr/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/hu/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/hu/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/hu/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/hu/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/it/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/it/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/it/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/it/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/ja/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/ja/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/ja/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/ja/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/ko/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/ko/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/ko/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/ko/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/lv/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/lv/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/lv/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/lv/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/nb/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/nb/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/nb/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/nb/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/nl/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/nl/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/nl/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/nl/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/pt_BR/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/pt_BR/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/pt_BR/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/pt_BR/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/ru/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/ru/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/ru/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/ru/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/sr/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/sr/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/sr/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/sr/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/uk/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/uk/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/uk/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/uk/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/vi/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/vi/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/vi/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/vi/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/zh/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/zh/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/zh/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/zh/LC_MESSAGES/main.mo +0 -0
- data/samples/cgi/locale/zh_TW/LC_MESSAGES/helloerb1.mo +0 -0
- data/samples/cgi/locale/zh_TW/LC_MESSAGES/helloerb2.mo +0 -0
- data/samples/cgi/locale/zh_TW/LC_MESSAGES/hellolib.mo +0 -0
- data/samples/cgi/locale/zh_TW/LC_MESSAGES/main.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/bg/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/bs/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/ca/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/cs/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/de/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/el/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/eo/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/es/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/fr/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/hr/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/hu/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/it/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/ja/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/ko/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/lv/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/nb/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/nl/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/pt_BR/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/ru/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/sr/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/sv/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/uk/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/vi/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/zh/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello2.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello_glade2.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello_gtk2.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello_gtk_builder.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello_noop.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello_plural.mo +0 -0
- data/samples/locale/zh_TW/LC_MESSAGES/hello_tk.mo +0 -0
- data/samples/po/bg/hello_gtk_builder.po +19 -0
- data/samples/po/bs/hello_gtk_builder.po +19 -0
- data/samples/po/ca/hello_gtk_builder.po +19 -0
- data/samples/po/cs/hello_gtk_builder.po +19 -0
- data/samples/po/de/hello_gtk_builder.po +19 -0
- data/samples/po/el/hello_gtk_builder.po +19 -0
- data/samples/po/eo/hello_gtk_builder.po +19 -0
- data/samples/po/es/hello_gtk_builder.po +19 -0
- data/samples/po/fr/hello_gtk_builder.po +19 -0
- data/samples/po/hello.pot +24 -0
- data/samples/po/hello2.pot +33 -0
- data/samples/po/hello_glade2.pot +31 -0
- data/samples/po/hello_gtk2.pot +23 -0
- data/samples/po/hello_gtk_builder.pot +20 -0
- data/samples/po/hello_noop.pot +27 -0
- data/samples/po/hello_plural.pot +27 -0
- data/samples/po/hello_tk.pot +23 -0
- data/samples/po/hr/hello_gtk_builder.po +19 -0
- data/samples/po/hu/hello_gtk_builder.po +19 -0
- data/samples/po/it/hello_gtk_builder.po +19 -0
- data/samples/po/ja/hello_gtk_builder.po +19 -0
- data/samples/po/ko/hello_gtk_builder.po +19 -0
- data/samples/po/lv/hello_gtk_builder.po +19 -0
- data/samples/po/nb/hello_gtk_builder.po +19 -0
- data/samples/po/nl/hello_gtk_builder.po +19 -0
- data/samples/po/pt_BR/hello_gtk_builder.po +19 -0
- data/samples/po/ru/hello_gtk_builder.po +19 -0
- data/samples/po/sr/hello_gtk_builder.po +19 -0
- data/samples/po/sv/hello_gtk_builder.po +19 -0
- data/samples/po/uk/hello_gtk_builder.po +19 -0
- data/samples/po/vi/hello_gtk_builder.po +19 -0
- data/samples/po/zh/hello_gtk_builder.po +19 -0
- data/samples/po/zh_TW/hello_gtk_builder.po +19 -0
- data/src/po_parser.ry +25 -25
- data/test/locale/cr/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/da/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/da/LC_MESSAGES/plural_error.mo +0 -0
- data/test/locale/fr/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/fr/LC_MESSAGES/plural_error.mo +0 -0
- data/test/locale/fr/LC_MESSAGES/test1.mo +0 -0
- data/test/locale/fr/LC_MESSAGES/test2.mo +0 -0
- data/test/locale/ir/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/_.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/backslash.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/non_ascii.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/np_.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/ns_.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/p_.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/plural_error.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/rubyparser.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/s_.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/test1.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/test2.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/test3.mo +0 -0
- data/test/locale/ja/LC_MESSAGES/untranslated.mo +0 -0
- data/test/locale/la/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/la/LC_MESSAGES/plural_error.mo +0 -0
- data/test/locale/li/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/li/LC_MESSAGES/plural_error.mo +0 -0
- data/test/locale/po/LC_MESSAGES/plural.mo +0 -0
- data/test/locale/sl/LC_MESSAGES/plural.mo +0 -0
- data/test/po/_.pot +162 -0
- data/test/po/backslash.pot +23 -0
- data/test/po/non_ascii.pot +23 -0
- data/test/po/np_.pot +48 -0
- data/test/po/ns_.pot +73 -0
- data/test/po/p_.pot +50 -0
- data/test/po/s_.pot +55 -0
- data/test/po/untranslated.pot +23 -0
- data/test/test_locale_path.rb +25 -3
- data/test/{tools/test_po.rb → test_po.rb} +217 -210
- data/test/test_po_entry.rb +107 -53
- data/test/test_text_domain.rb +38 -0
- data/test/tools/test_msgmerge.rb +206 -5
- data/test/tools/test_task.rb +287 -0
- data/test/tools/test_xgettext.rb +3 -1
- metadata +373 -4
- data/samples/cgi/Rakefile +0 -27
@@ -0,0 +1,23 @@
|
|
1
|
+
# SOME DESCRIPTIVE TITLE.
|
2
|
+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
3
|
+
# This file is distributed under the same license as the gettext package.
|
4
|
+
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
5
|
+
#
|
6
|
+
#, fuzzy
|
7
|
+
msgid ""
|
8
|
+
msgstr ""
|
9
|
+
"Project-Id-Version: gettext 3.0.1\n"
|
10
|
+
"Report-Msgid-Bugs-To: \n"
|
11
|
+
"POT-Creation-Date: 2013-09-03 21:25+0900\n"
|
12
|
+
"PO-Revision-Date: 2013-09-03 21:25+0900\n"
|
13
|
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
|
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
|
+
"Language: \n"
|
16
|
+
"MIME-Version: 1.0\n"
|
17
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
18
|
+
"Content-Transfer-Encoding: 8bit\n"
|
19
|
+
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
20
|
+
|
21
|
+
#: ../fixtures/non_ascii.rb:10
|
22
|
+
msgid "こんにちは"
|
23
|
+
msgstr ""
|
data/test/po/np_.pot
ADDED
@@ -0,0 +1,48 @@
|
|
1
|
+
# SOME DESCRIPTIVE TITLE.
|
2
|
+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
3
|
+
# This file is distributed under the same license as the gettext package.
|
4
|
+
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
5
|
+
#
|
6
|
+
#, fuzzy
|
7
|
+
msgid ""
|
8
|
+
msgstr ""
|
9
|
+
"Project-Id-Version: gettext 3.0.1\n"
|
10
|
+
"Report-Msgid-Bugs-To: \n"
|
11
|
+
"POT-Creation-Date: 2013-09-03 21:25+0900\n"
|
12
|
+
"PO-Revision-Date: 2013-09-03 21:25+0900\n"
|
13
|
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
|
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
|
+
"Language: \n"
|
16
|
+
"MIME-Version: 1.0\n"
|
17
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
18
|
+
"Content-Transfer-Encoding: 8bit\n"
|
19
|
+
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
20
|
+
|
21
|
+
#: ../fixtures/np_.rb:28 ../fixtures/np_.rb:29 ../fixtures/np_.rb:33
|
22
|
+
#: ../fixtures/np_.rb:34
|
23
|
+
msgctxt "Magazine"
|
24
|
+
msgid "a book"
|
25
|
+
msgid_plural "%{num} books"
|
26
|
+
msgstr[0] ""
|
27
|
+
msgstr[1] ""
|
28
|
+
|
29
|
+
#: ../fixtures/np_.rb:38 ../fixtures/np_.rb:39
|
30
|
+
msgctxt "Hardcover"
|
31
|
+
msgid "a book"
|
32
|
+
msgid_plural "%{num} books"
|
33
|
+
msgstr[0] ""
|
34
|
+
msgstr[1] ""
|
35
|
+
|
36
|
+
#: ../fixtures/np_.rb:43 ../fixtures/np_.rb:44
|
37
|
+
msgctxt "Magaine"
|
38
|
+
msgid "I have a magazine"
|
39
|
+
msgid_plural "I have %{num} magazines"
|
40
|
+
msgstr[0] ""
|
41
|
+
msgstr[1] ""
|
42
|
+
|
43
|
+
#: ../fixtures/np_.rb:48 ../fixtures/np_.rb:49
|
44
|
+
msgctxt "Hardcover"
|
45
|
+
msgid "a picture"
|
46
|
+
msgid_plural "%{num} pictures"
|
47
|
+
msgstr[0] ""
|
48
|
+
msgstr[1] ""
|
data/test/po/ns_.pot
ADDED
@@ -0,0 +1,73 @@
|
|
1
|
+
# SOME DESCRIPTIVE TITLE.
|
2
|
+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
3
|
+
# This file is distributed under the same license as the gettext package.
|
4
|
+
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
5
|
+
#
|
6
|
+
#, fuzzy
|
7
|
+
msgid ""
|
8
|
+
msgstr ""
|
9
|
+
"Project-Id-Version: gettext 3.0.1\n"
|
10
|
+
"Report-Msgid-Bugs-To: \n"
|
11
|
+
"POT-Creation-Date: 2013-09-03 21:25+0900\n"
|
12
|
+
"PO-Revision-Date: 2013-09-03 21:25+0900\n"
|
13
|
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
|
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
|
+
"Language: \n"
|
16
|
+
"MIME-Version: 1.0\n"
|
17
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
18
|
+
"Content-Transfer-Encoding: 8bit\n"
|
19
|
+
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
20
|
+
|
21
|
+
#: ../fixtures/ns_.rb:28 ../fixtures/ns_.rb:32
|
22
|
+
msgid "AAA|BBB"
|
23
|
+
msgid_plural "CCC"
|
24
|
+
msgstr[0] ""
|
25
|
+
msgstr[1] ""
|
26
|
+
|
27
|
+
#: ../fixtures/ns_.rb:36
|
28
|
+
msgid "AAA"
|
29
|
+
msgid_plural "BBB"
|
30
|
+
msgstr[0] ""
|
31
|
+
msgstr[1] ""
|
32
|
+
|
33
|
+
#: ../fixtures/ns_.rb:40
|
34
|
+
msgid "AAA|CCC"
|
35
|
+
msgid_plural "DDD"
|
36
|
+
msgstr[0] ""
|
37
|
+
msgstr[1] ""
|
38
|
+
|
39
|
+
#: ../fixtures/ns_.rb:44
|
40
|
+
msgid "AAA|BBB|CCC"
|
41
|
+
msgid_plural "DDD"
|
42
|
+
msgstr[0] ""
|
43
|
+
msgstr[1] ""
|
44
|
+
|
45
|
+
#: ../fixtures/ns_.rb:48
|
46
|
+
msgid "AAA$BBB"
|
47
|
+
msgid_plural "CCC"
|
48
|
+
msgstr[0] ""
|
49
|
+
msgstr[1] ""
|
50
|
+
|
51
|
+
#: ../fixtures/ns_.rb:52
|
52
|
+
msgid "AAA$B|BB"
|
53
|
+
msgid_plural "CCC"
|
54
|
+
msgstr[0] ""
|
55
|
+
msgstr[1] ""
|
56
|
+
|
57
|
+
#: ../fixtures/ns_.rb:56
|
58
|
+
msgid "AAA$B|CC"
|
59
|
+
msgid_plural "DDD"
|
60
|
+
msgstr[0] ""
|
61
|
+
msgstr[1] ""
|
62
|
+
|
63
|
+
#: ../fixtures/ns_.rb:60
|
64
|
+
msgid "AAA|CCC|BBB"
|
65
|
+
msgid_plural "DDD"
|
66
|
+
msgstr[0] ""
|
67
|
+
msgstr[1] ""
|
68
|
+
|
69
|
+
#: ../fixtures/ns_/custom.rb:28
|
70
|
+
msgid "context|context$message"
|
71
|
+
msgid_plural "context|context$messages"
|
72
|
+
msgstr[0] ""
|
73
|
+
msgstr[1] ""
|
data/test/po/p_.pot
ADDED
@@ -0,0 +1,50 @@
|
|
1
|
+
# SOME DESCRIPTIVE TITLE.
|
2
|
+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
3
|
+
# This file is distributed under the same license as the gettext package.
|
4
|
+
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
5
|
+
#
|
6
|
+
#, fuzzy
|
7
|
+
msgid ""
|
8
|
+
msgstr ""
|
9
|
+
"Project-Id-Version: gettext 3.0.1\n"
|
10
|
+
"Report-Msgid-Bugs-To: \n"
|
11
|
+
"POT-Creation-Date: 2013-09-03 21:25+0900\n"
|
12
|
+
"PO-Revision-Date: 2013-09-03 21:25+0900\n"
|
13
|
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
|
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
|
+
"Language: \n"
|
16
|
+
"MIME-Version: 1.0\n"
|
17
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
18
|
+
"Content-Transfer-Encoding: 8bit\n"
|
19
|
+
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
20
|
+
|
21
|
+
#: ../fixtures/p_.rb:29 ../fixtures/p_.rb:33
|
22
|
+
msgctxt "AAA"
|
23
|
+
msgid "BBB"
|
24
|
+
msgstr ""
|
25
|
+
|
26
|
+
#: ../fixtures/p_.rb:37
|
27
|
+
msgctxt "AAA|BBB"
|
28
|
+
msgid "CCC"
|
29
|
+
msgstr ""
|
30
|
+
|
31
|
+
#: ../fixtures/p_.rb:41
|
32
|
+
msgctxt "AAA"
|
33
|
+
msgid "CCC"
|
34
|
+
msgstr ""
|
35
|
+
|
36
|
+
#: ../fixtures/p_.rb:45
|
37
|
+
msgctxt "CCC"
|
38
|
+
msgid "BBB"
|
39
|
+
msgstr ""
|
40
|
+
|
41
|
+
#: ../fixtures/p_.rb:49
|
42
|
+
msgid "BBB"
|
43
|
+
msgstr ""
|
44
|
+
|
45
|
+
#. TRANSLATORS:please translate 'name' in the context of 'program'.
|
46
|
+
#. Hint: the translation should NOT contain the translation of 'program'.
|
47
|
+
#: ../fixtures/p_.rb:55
|
48
|
+
msgctxt "program"
|
49
|
+
msgid "name"
|
50
|
+
msgstr ""
|
data/test/po/s_.pot
ADDED
@@ -0,0 +1,55 @@
|
|
1
|
+
# SOME DESCRIPTIVE TITLE.
|
2
|
+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
3
|
+
# This file is distributed under the same license as the gettext package.
|
4
|
+
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
5
|
+
#
|
6
|
+
#, fuzzy
|
7
|
+
msgid ""
|
8
|
+
msgstr ""
|
9
|
+
"Project-Id-Version: gettext 3.0.1\n"
|
10
|
+
"Report-Msgid-Bugs-To: \n"
|
11
|
+
"POT-Creation-Date: 2013-09-03 21:25+0900\n"
|
12
|
+
"PO-Revision-Date: 2013-09-03 21:25+0900\n"
|
13
|
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
|
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
|
+
"Language: \n"
|
16
|
+
"MIME-Version: 1.0\n"
|
17
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
18
|
+
"Content-Transfer-Encoding: 8bit\n"
|
19
|
+
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
20
|
+
|
21
|
+
#: ../fixtures/s_.rb:28 ../fixtures/s_.rb:32
|
22
|
+
msgid "AAA|BBB"
|
23
|
+
msgstr ""
|
24
|
+
|
25
|
+
#: ../fixtures/s_.rb:36
|
26
|
+
msgid "AAA"
|
27
|
+
msgstr ""
|
28
|
+
|
29
|
+
#: ../fixtures/s_.rb:40
|
30
|
+
msgid "AAA|CCC"
|
31
|
+
msgstr ""
|
32
|
+
|
33
|
+
#: ../fixtures/s_.rb:44
|
34
|
+
msgid "AAA|BBB|CCC"
|
35
|
+
msgstr ""
|
36
|
+
|
37
|
+
#: ../fixtures/s_.rb:48
|
38
|
+
msgid "AAA$BBB"
|
39
|
+
msgstr ""
|
40
|
+
|
41
|
+
#: ../fixtures/s_.rb:52
|
42
|
+
msgid "AAA$B|BB"
|
43
|
+
msgstr ""
|
44
|
+
|
45
|
+
#: ../fixtures/s_.rb:56
|
46
|
+
msgid "AAA$B|CC"
|
47
|
+
msgstr ""
|
48
|
+
|
49
|
+
#: ../fixtures/s_.rb:60
|
50
|
+
msgid "AAA|CCC|BBB"
|
51
|
+
msgstr ""
|
52
|
+
|
53
|
+
#: ../fixtures/s_/custom.rb:28
|
54
|
+
msgid "context|context$message"
|
55
|
+
msgstr ""
|
@@ -0,0 +1,23 @@
|
|
1
|
+
# SOME DESCRIPTIVE TITLE.
|
2
|
+
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
3
|
+
# This file is distributed under the same license as the gettext package.
|
4
|
+
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
5
|
+
#
|
6
|
+
#, fuzzy
|
7
|
+
msgid ""
|
8
|
+
msgstr ""
|
9
|
+
"Project-Id-Version: gettext 3.0.1\n"
|
10
|
+
"Report-Msgid-Bugs-To: \n"
|
11
|
+
"POT-Creation-Date: 2013-09-03 21:25+0900\n"
|
12
|
+
"PO-Revision-Date: 2013-09-03 21:25+0900\n"
|
13
|
+
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
|
+
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
|
+
"Language: \n"
|
16
|
+
"MIME-Version: 1.0\n"
|
17
|
+
"Content-Type: text/plain; charset=UTF-8\n"
|
18
|
+
"Content-Transfer-Encoding: 8bit\n"
|
19
|
+
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
|
20
|
+
|
21
|
+
#: ../fixtures/untranslated.rb:10
|
22
|
+
msgid "untranslated"
|
23
|
+
msgstr ""
|
data/test/test_locale_path.rb
CHANGED
@@ -1,3 +1,25 @@
|
|
1
|
+
# -*- coding: utf-8 -*-
|
2
|
+
#
|
3
|
+
# Copyright (C) 2013 Haruka Yoshihara <yoshihara@clear-code.com>
|
4
|
+
# Copyright (C) 2012-2013 Kouhei Sutou <kou@clear-code.com>
|
5
|
+
# Copyright (C) 2010 masone (Christian Felder) <ema@rh-productions.ch>
|
6
|
+
# Copyright (C) 2009-2010 Masao Mutoh
|
7
|
+
#
|
8
|
+
# License: Ruby's or LGPL
|
9
|
+
#
|
10
|
+
# This library is free software: you can redistribute it and/or modify
|
11
|
+
# it under the terms of the GNU Lesser General Public License as published by
|
12
|
+
# the Free Software Foundation, either version 3 of the License, or
|
13
|
+
# (at your option) any later version.
|
14
|
+
#
|
15
|
+
# This library is distributed in the hope that it will be useful,
|
16
|
+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
17
|
+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
18
|
+
# GNU Lesser General Public License for more details.
|
19
|
+
#
|
20
|
+
# You should have received a copy of the GNU Lesser General Public License
|
21
|
+
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
22
|
+
|
1
23
|
require 'fixtures/simple'
|
2
24
|
|
3
25
|
class TestLocalePath < Test::Unit::TestCase
|
@@ -59,13 +81,13 @@ class TestLocalePath < Test::Unit::TestCase
|
|
59
81
|
GetText::LocalePath.memoize_clear
|
60
82
|
ENV["GETTEXT_PATH"] = path1
|
61
83
|
default_path_rules = GetText::LocalePath.default_path_rules
|
62
|
-
|
84
|
+
assert_match(Regexp.compile(path1), default_path_rules[0])
|
63
85
|
|
64
86
|
GetText::LocalePath.memoize_clear
|
65
87
|
ENV["GETTEXT_PATH"] = "#{path1},#{path2}"
|
66
88
|
default_path_rules = GetText::LocalePath.default_path_rules
|
67
|
-
|
68
|
-
|
89
|
+
assert_match(Regexp.compile(path1), default_path_rules[0])
|
90
|
+
assert_match(Regexp.compile(path2), default_path_rules[1])
|
69
91
|
end
|
70
92
|
|
71
93
|
class TestDefaultPathRules < self
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# -*- coding: utf-8 -*-
|
2
2
|
#
|
3
3
|
# Copyright (C) 2012 Haruka Yoshihara <yoshihara@clear-code.com>
|
4
|
-
# Copyright (C) 2012 Kouhei Sutou <kou@clear-code.com>
|
4
|
+
# Copyright (C) 2012-2013 Kouhei Sutou <kou@clear-code.com>
|
5
5
|
#
|
6
6
|
# License: Ruby's or LGPL
|
7
7
|
#
|
@@ -204,104 +204,144 @@ class TestPO < Test::Unit::TestCase
|
|
204
204
|
end
|
205
205
|
end
|
206
206
|
|
207
|
-
class
|
207
|
+
class TestOrder < self
|
208
208
|
def setup
|
209
209
|
@po = GetText::PO.new
|
210
|
-
|
211
|
-
@po
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
hello = "hello"
|
216
|
-
hello_translation = "こんにちは"
|
217
|
-
hello_references = ["file.rb:10"]
|
218
|
-
hello_comment = "#: file.rb:10"
|
219
|
-
bye = "bye"
|
220
|
-
bye_translation = "さようなら"
|
221
|
-
bye_references = ["file.rb:20"]
|
222
|
-
bye_comment = "#: file.rb:20"
|
210
|
+
parser = GetText::POParser.new
|
211
|
+
parser.parse(<<-PO, @po)
|
212
|
+
#: hello.rb:2
|
213
|
+
msgid "World"
|
214
|
+
msgstr ""
|
223
215
|
|
224
|
-
|
225
|
-
|
216
|
+
#: hello.rb:1
|
217
|
+
msgid "Hello"
|
218
|
+
msgstr ""
|
226
219
|
|
227
|
-
|
228
|
-
|
220
|
+
#: hello.rb:3
|
221
|
+
msgid "Hello World"
|
222
|
+
msgstr ""
|
223
|
+
PO
|
224
|
+
end
|
229
225
|
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
226
|
+
def test_nil
|
227
|
+
@po.order = nil
|
228
|
+
assert_equal(<<-PO, @po.to_s)
|
229
|
+
#: hello.rb:2
|
230
|
+
msgid "World"
|
234
231
|
msgstr ""
|
235
|
-
#{expected_header}
|
236
232
|
|
237
|
-
|
238
|
-
msgid "
|
239
|
-
msgstr "
|
233
|
+
#: hello.rb:1
|
234
|
+
msgid "Hello"
|
235
|
+
msgstr ""
|
240
236
|
|
241
|
-
|
242
|
-
msgid "
|
243
|
-
msgstr "
|
244
|
-
|
245
|
-
assert_equal(expected_po, @po.to_s)
|
237
|
+
#: hello.rb:3
|
238
|
+
msgid "Hello World"
|
239
|
+
msgstr ""
|
240
|
+
PO
|
246
241
|
end
|
247
242
|
|
248
|
-
def
|
249
|
-
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
bye_translation = "さようなら"
|
255
|
-
bye_references = ["test.rb:10"]
|
256
|
-
bye_comment = "#: test.rb:10"
|
243
|
+
def test_msgid
|
244
|
+
@po.order = :msgid
|
245
|
+
assert_equal(<<-PO, @po.to_s)
|
246
|
+
#: hello.rb:1
|
247
|
+
msgid "Hello"
|
248
|
+
msgstr ""
|
257
249
|
|
258
|
-
|
259
|
-
|
250
|
+
#: hello.rb:3
|
251
|
+
msgid "Hello World"
|
252
|
+
msgstr ""
|
260
253
|
|
261
|
-
|
262
|
-
|
254
|
+
#: hello.rb:2
|
255
|
+
msgid "World"
|
256
|
+
msgstr ""
|
257
|
+
PO
|
258
|
+
end
|
263
259
|
|
264
|
-
|
265
|
-
|
266
|
-
|
267
|
-
|
260
|
+
def test_references
|
261
|
+
@po.order = :references
|
262
|
+
assert_equal(<<-PO, @po.to_s)
|
263
|
+
#: hello.rb:1
|
264
|
+
msgid "Hello"
|
268
265
|
msgstr ""
|
269
|
-
#{expected_header}
|
270
266
|
|
271
|
-
|
272
|
-
msgid "
|
273
|
-
msgstr "
|
267
|
+
#: hello.rb:2
|
268
|
+
msgid "World"
|
269
|
+
msgstr ""
|
274
270
|
|
275
|
-
|
276
|
-
msgid "
|
277
|
-
msgstr "
|
278
|
-
|
279
|
-
assert_equal(expected_po, @po.to_s)
|
271
|
+
#: hello.rb:3
|
272
|
+
msgid "Hello World"
|
273
|
+
msgstr ""
|
274
|
+
PO
|
280
275
|
end
|
276
|
+
end
|
281
277
|
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
hello_comment = "#: file.rb:10"
|
287
|
-
bye = "bye"
|
288
|
-
bye_translation = "さようなら"
|
289
|
-
bye_references = ["file:2.rb:10"]
|
290
|
-
bye_comment = "#: file:2.rb:10"
|
278
|
+
class TestToS < self
|
279
|
+
def setup
|
280
|
+
@po = GetText::PO.new
|
281
|
+
end
|
291
282
|
|
292
|
-
|
293
|
-
|
283
|
+
class TestHeader < self
|
284
|
+
def test_no_entry
|
285
|
+
@po[""] = <<-HEADER
|
286
|
+
Project-Id-Version: test 1.0.0
|
287
|
+
POT-Creation-Date: 2012-10-31 12:40+0900
|
288
|
+
PO-Revision-Date: 2012-11-01 17:46+0900
|
289
|
+
Last-Translator: FULLNAME <MAIL@ADDRESS>
|
290
|
+
Language-Team: Japanese
|
291
|
+
Language:
|
292
|
+
MIME-Version: 1.0
|
293
|
+
Content-Type: text/plain; charset=UTF-8
|
294
|
+
Content-Transfer-Encoding: 8bit
|
295
|
+
Plural-Forms: nplurals=2; plural=(n != 1)
|
296
|
+
HEADER
|
297
|
+
@po[""].translator_comment = <<-HEADER_COMMENT
|
298
|
+
Japanese translations for test package.
|
299
|
+
Copyright (C) 2012 THE PACKAGE'S COPYRIGHT HOLDER
|
300
|
+
This file is distributed under the same license as the PACKAGE package.
|
301
|
+
FULLNAME <MAIL@ADDRESS>, 2012.
|
294
302
|
|
295
|
-
|
296
|
-
@po[bye].references = bye_references
|
303
|
+
HEADER_COMMENT
|
297
304
|
|
298
|
-
|
299
|
-
#
|
305
|
+
assert_equal(<<-PO, @po.to_s)
|
306
|
+
# Japanese translations for test package.
|
307
|
+
# Copyright (C) 2012 THE PACKAGE'S COPYRIGHT HOLDER
|
308
|
+
# This file is distributed under the same license as the PACKAGE package.
|
309
|
+
# FULLNAME <MAIL@ADDRESS>, 2012.
|
300
310
|
#
|
301
311
|
msgid ""
|
302
312
|
msgstr ""
|
303
|
-
|
313
|
+
"Project-Id-Version: test 1.0.0\\n"
|
314
|
+
"POT-Creation-Date: 2012-10-31 12:40+0900\\n"
|
315
|
+
"PO-Revision-Date: 2012-11-01 17:46+0900\\n"
|
316
|
+
"Last-Translator: FULLNAME <MAIL@ADDRESS>\\n"
|
317
|
+
"Language-Team: Japanese\\n"
|
318
|
+
"Language: \\n"
|
319
|
+
"MIME-Version: 1.0\\n"
|
320
|
+
"Content-Type: text/plain; charset=UTF-8\\n"
|
321
|
+
"Content-Transfer-Encoding: 8bit\\n"
|
322
|
+
"Plural-Forms: nplurals=2; plural=(n != 1)\\n"
|
323
|
+
PO
|
324
|
+
end
|
325
|
+
end
|
326
|
+
|
327
|
+
class TestReferenceComment < self
|
328
|
+
def test_same_filename
|
329
|
+
hello = "hello"
|
330
|
+
hello_translation = "こんにちは"
|
331
|
+
hello_references = ["file.rb:10"]
|
332
|
+
hello_comment = "#: file.rb:10"
|
333
|
+
bye = "bye"
|
334
|
+
bye_translation = "さようなら"
|
335
|
+
bye_references = ["file.rb:20"]
|
336
|
+
bye_comment = "#: file.rb:20"
|
337
|
+
|
338
|
+
@po[hello] = hello_translation
|
339
|
+
@po[hello].references = hello_references
|
340
|
+
|
341
|
+
@po[bye] = bye_translation
|
342
|
+
@po[bye].references = bye_references
|
304
343
|
|
344
|
+
expected_po =<<EOP
|
305
345
|
#{hello_comment}
|
306
346
|
msgid "#{hello}"
|
307
347
|
msgstr "#{hello_translation}"
|
@@ -310,32 +350,26 @@ msgstr "#{hello_translation}"
|
|
310
350
|
msgid "#{bye}"
|
311
351
|
msgstr "#{bye_translation}"
|
312
352
|
EOP
|
313
|
-
|
314
|
-
|
353
|
+
assert_equal(expected_po, @po.to_s)
|
354
|
+
end
|
315
355
|
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
356
|
+
def test_different_filename
|
357
|
+
hello = "hello"
|
358
|
+
hello_translation = "こんにちは"
|
359
|
+
hello_references = ["file.rb:10"]
|
360
|
+
hello_comment = "#: file.rb:10"
|
361
|
+
bye = "bye"
|
362
|
+
bye_translation = "さようなら"
|
363
|
+
bye_references = ["test.rb:10"]
|
364
|
+
bye_comment = "#: test.rb:10"
|
325
365
|
|
326
|
-
|
327
|
-
|
366
|
+
@po[hello] = hello_translation
|
367
|
+
@po[hello].references = hello_references
|
328
368
|
|
329
|
-
|
330
|
-
|
331
|
-
|
332
|
-
expected_po =<<EOP
|
333
|
-
#{expected_header_comment}
|
334
|
-
#
|
335
|
-
msgid ""
|
336
|
-
msgstr ""
|
337
|
-
#{expected_header}
|
369
|
+
@po[bye] = bye_translation
|
370
|
+
@po[bye].references = bye_references
|
338
371
|
|
372
|
+
expected_po =<<EOP
|
339
373
|
#{hello_comment}
|
340
374
|
msgid "#{hello}"
|
341
375
|
msgstr "#{hello_translation}"
|
@@ -344,32 +378,26 @@ msgstr "#{hello_translation}"
|
|
344
378
|
msgid "#{bye}"
|
345
379
|
msgstr "#{bye_translation}"
|
346
380
|
EOP
|
347
|
-
|
348
|
-
|
381
|
+
assert_equal(expected_po, @po.to_s)
|
382
|
+
end
|
349
383
|
|
350
|
-
|
351
|
-
|
352
|
-
|
353
|
-
|
354
|
-
|
355
|
-
|
356
|
-
|
357
|
-
|
358
|
-
|
384
|
+
def test_including_colon_filename
|
385
|
+
hello = "hello"
|
386
|
+
hello_translation = "こんにちは"
|
387
|
+
hello_references = ["file.rb:10"]
|
388
|
+
hello_comment = "#: file.rb:10"
|
389
|
+
bye = "bye"
|
390
|
+
bye_translation = "さようなら"
|
391
|
+
bye_references = ["file:2.rb:10"]
|
392
|
+
bye_comment = "#: file:2.rb:10"
|
359
393
|
|
360
|
-
|
361
|
-
|
394
|
+
@po[hello] = hello_translation
|
395
|
+
@po[hello].references = hello_references
|
362
396
|
|
363
|
-
|
364
|
-
|
365
|
-
|
366
|
-
expected_po =<<EOP
|
367
|
-
#{expected_header_comment}
|
368
|
-
#
|
369
|
-
msgid ""
|
370
|
-
msgstr ""
|
371
|
-
#{expected_header}
|
397
|
+
@po[bye] = bye_translation
|
398
|
+
@po[bye].references = bye_references
|
372
399
|
|
400
|
+
expected_po =<<EOP
|
373
401
|
#{hello_comment}
|
374
402
|
msgid "#{hello}"
|
375
403
|
msgstr "#{hello_translation}"
|
@@ -378,123 +406,102 @@ msgstr "#{hello_translation}"
|
|
378
406
|
msgid "#{bye}"
|
379
407
|
msgstr "#{bye_translation}"
|
380
408
|
EOP
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
def test_obsolete_comment
|
385
|
-
hello = "hello"
|
386
|
-
hello_translation = "こんにちは"
|
387
|
-
hello_references = ["file.rb:10"]
|
409
|
+
assert_equal(expected_po, @po.to_s)
|
410
|
+
end
|
388
411
|
|
389
|
-
|
390
|
-
|
412
|
+
def test_no_file_number
|
413
|
+
hello = "hello"
|
414
|
+
hello_translation = "こんにちは"
|
415
|
+
hello_references = ["file.rb"]
|
416
|
+
hello_comment = "#: file.rb"
|
417
|
+
bye = "bye"
|
418
|
+
bye_translation = "さようなら"
|
419
|
+
bye_references = ["test.rb"]
|
420
|
+
bye_comment = "#: test.rb"
|
391
421
|
|
392
|
-
|
422
|
+
@po[hello] = hello_translation
|
423
|
+
@po[hello].references = hello_references
|
393
424
|
|
394
|
-
|
395
|
-
|
396
|
-
#{expected_header_comment}
|
397
|
-
#
|
398
|
-
msgid ""
|
399
|
-
msgstr ""
|
400
|
-
#{expected_header}
|
425
|
+
@po[bye] = bye_translation
|
426
|
+
@po[bye].references = bye_references
|
401
427
|
|
428
|
+
expected_po =<<EOP
|
402
429
|
#{hello_comment}
|
403
430
|
msgid "#{hello}"
|
404
431
|
msgstr "#{hello_translation}"
|
405
432
|
|
406
|
-
#{
|
433
|
+
#{bye_comment}
|
434
|
+
msgid "#{bye}"
|
435
|
+
msgstr "#{bye_translation}"
|
407
436
|
EOP
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
def test_obsolete_comment_without_header
|
412
|
-
@po = GetText::PO.new
|
413
|
-
|
414
|
-
hello = "hello"
|
415
|
-
hello_translation = "こんにちは"
|
416
|
-
hello_references = ["file.rb:10"]
|
437
|
+
assert_equal(expected_po, @po.to_s)
|
438
|
+
end
|
417
439
|
|
418
|
-
|
419
|
-
|
440
|
+
def test_multiple_filename
|
441
|
+
hello = "hello"
|
442
|
+
hello_translation = "こんにちは"
|
443
|
+
hello_references = ["file.rb:10"]
|
444
|
+
hello_comment = "#: file.rb:10"
|
445
|
+
bye = "bye"
|
446
|
+
bye_translation = "さようなら"
|
447
|
+
bye_references = ["test.rb:10", "file.rb:110", "file.rb:20"]
|
448
|
+
bye_comment = "#: file.rb:20 file.rb:110 test.rb:10"
|
420
449
|
|
421
|
-
|
450
|
+
@po[hello] = hello_translation
|
451
|
+
@po[hello].references = hello_references
|
422
452
|
|
423
|
-
|
424
|
-
|
453
|
+
@po[bye] = bye_translation
|
454
|
+
@po[bye].references = bye_references
|
425
455
|
|
456
|
+
expected_po =<<EOP
|
426
457
|
#{hello_comment}
|
427
458
|
msgid "#{hello}"
|
428
459
|
msgstr "#{hello_translation}"
|
429
460
|
|
430
|
-
#{
|
461
|
+
#{bye_comment}
|
462
|
+
msgid "#{bye}"
|
463
|
+
msgstr "#{bye_translation}"
|
431
464
|
EOP
|
432
|
-
|
433
|
-
end
|
434
|
-
|
435
|
-
private
|
436
|
-
def header
|
437
|
-
<<EOH
|
438
|
-
Project-Id-Version: test 1.0.0
|
439
|
-
POT-Creation-Date: 2012-10-31 12:40+0900
|
440
|
-
PO-Revision-Date: 2012-11-01 17:46+0900
|
441
|
-
Last-Translator: FULLNAME <MAIL@ADDRESS>
|
442
|
-
Language-Team: Japanese
|
443
|
-
Language:
|
444
|
-
MIME-Version: 1.0
|
445
|
-
Content-Type: text/plain; charset=UTF-8
|
446
|
-
Content-Transfer-Encoding: 8bit
|
447
|
-
Plural-Forms: nplurals=2; plural=(n != 1)
|
448
|
-
EOH
|
449
|
-
end
|
450
|
-
|
451
|
-
def header_comment
|
452
|
-
<<EOC
|
453
|
-
Japanese translations for test package.
|
454
|
-
Copyright (C) 2012 THE PACKAGE'S COPYRIGHT HOLDER
|
455
|
-
This file is distributed under the same license as the PACKAGE package.
|
456
|
-
FULLNAME <MAIL@ADDRESS>, 2012.
|
457
|
-
|
458
|
-
EOC
|
459
|
-
end
|
460
|
-
|
461
|
-
def expected_header
|
462
|
-
expected_header = header.split("\n").collect do |line|
|
463
|
-
"\"#{line}\\n\""
|
465
|
+
assert_equal(expected_po, @po.to_s)
|
464
466
|
end
|
465
|
-
expected_header.join("\n")
|
466
|
-
end
|
467
467
|
|
468
|
-
|
469
|
-
|
470
|
-
|
468
|
+
class TestIncludeReferenceComment < self
|
469
|
+
def setup
|
470
|
+
super
|
471
|
+
@po["Hi"] = "Bonjour"
|
472
|
+
@po["Hi"].references = ["hi.rb:29"]
|
473
|
+
end
|
474
|
+
|
475
|
+
def test_false
|
476
|
+
assert_equal(<<-PO, @po.to_s(:include_reference_comment => false))
|
477
|
+
msgid "Hi"
|
478
|
+
msgstr "Bonjour"
|
479
|
+
PO
|
480
|
+
end
|
471
481
|
end
|
472
|
-
expected_header_comment.join("\n")
|
473
482
|
end
|
474
483
|
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
484
|
+
class TestObsoleteComment < self
|
485
|
+
def setup
|
486
|
+
@po = GetText::PO.new
|
487
|
+
@po["hello"] = ""
|
488
|
+
@po.set_comment(:last, <<-OBSOLETE_COMMENT)
|
489
|
+
# hello.rb:20
|
490
|
+
msgid "hi"
|
491
|
+
msgstr "Bonjour"
|
492
|
+
OBSOLETE_COMMENT
|
493
|
+
end
|
480
494
|
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
end
|
495
|
+
def test_default
|
496
|
+
assert_equal(<<-PO, @po.to_s)
|
497
|
+
msgid "hello"
|
498
|
+
msgstr ""
|
486
499
|
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
|
492
|
-
|
493
|
-
# test.rb:20
|
494
|
-
#~ msgid \"hi\"
|
495
|
-
#~ msgstr \"Bonjour\"
|
496
|
-
EOC
|
497
|
-
comment.chomp
|
500
|
+
# hello.rb:20
|
501
|
+
#~ msgid "hi"
|
502
|
+
#~ msgstr "Bonjour"
|
503
|
+
PO
|
504
|
+
end
|
498
505
|
end
|
499
506
|
end
|
500
507
|
end
|