gettext 3.1.9 → 3.2.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -39,11 +39,11 @@ msgstr ""
39
39
  msgid "Concatenates and merges PO files."
40
40
  msgstr ""
41
41
 
42
- #: ../lib/gettext/tools/msgcat.rb:211 ../lib/gettext/tools/msgfmt.rb:86 ../lib/gettext/tools/msginit.rb:92 ../lib/gettext/tools/msgmerge.rb:356 ../lib/gettext/tools/xgettext.rb:248
42
+ #: ../lib/gettext/tools/msgcat.rb:211 ../lib/gettext/tools/msgfmt.rb:86 ../lib/gettext/tools/msginit.rb:92 ../lib/gettext/tools/msgmerge.rb:361 ../lib/gettext/tools/xgettext.rb:248
43
43
  msgid "Specific options:"
44
44
  msgstr "特殊選項:"
45
45
 
46
- #: ../lib/gettext/tools/msgcat.rb:214 ../lib/gettext/tools/msgmerge.rb:364
46
+ #: ../lib/gettext/tools/msgcat.rb:214 ../lib/gettext/tools/msgmerge.rb:369
47
47
  #, fuzzy
48
48
  msgid "Write output to specified file"
49
49
  msgstr "輸出到指定檔案"
@@ -52,23 +52,23 @@ msgstr "輸出到指定檔案"
52
52
  msgid "(default: the standard output)"
53
53
  msgstr ""
54
54
 
55
- #: ../lib/gettext/tools/msgcat.rb:220 ../lib/gettext/tools/msgcat.rb:237 ../lib/gettext/tools/msgmerge.rb:369 ../lib/gettext/tools/msgmerge.rb:388 ../lib/gettext/tools/xgettext.rb:302
55
+ #: ../lib/gettext/tools/msgcat.rb:220 ../lib/gettext/tools/msgcat.rb:237 ../lib/gettext/tools/msgmerge.rb:374 ../lib/gettext/tools/msgmerge.rb:393 ../lib/gettext/tools/xgettext.rb:302
56
56
  msgid "Sort output by msgid"
57
57
  msgstr ""
58
58
 
59
- #: ../lib/gettext/tools/msgcat.rb:225 ../lib/gettext/tools/msgcat.rb:230 ../lib/gettext/tools/msgmerge.rb:376 ../lib/gettext/tools/msgmerge.rb:383
59
+ #: ../lib/gettext/tools/msgcat.rb:225 ../lib/gettext/tools/msgcat.rb:230 ../lib/gettext/tools/msgmerge.rb:381 ../lib/gettext/tools/msgmerge.rb:388
60
60
  msgid "Sort output by location"
61
61
  msgstr ""
62
62
 
63
- #: ../lib/gettext/tools/msgcat.rb:231 ../lib/gettext/tools/msgmerge.rb:377
63
+ #: ../lib/gettext/tools/msgcat.rb:231 ../lib/gettext/tools/msgmerge.rb:382
64
64
  msgid "It is same as --sort-by-location"
65
65
  msgstr ""
66
66
 
67
- #: ../lib/gettext/tools/msgcat.rb:232 ../lib/gettext/tools/msgcat.rb:239 ../lib/gettext/tools/msgmerge.rb:371 ../lib/gettext/tools/msgmerge.rb:378
67
+ #: ../lib/gettext/tools/msgcat.rb:232 ../lib/gettext/tools/msgcat.rb:239 ../lib/gettext/tools/msgmerge.rb:376 ../lib/gettext/tools/msgmerge.rb:383
68
68
  msgid "Just for GNU gettext's msgcat compatibility"
69
69
  msgstr ""
70
70
 
71
- #: ../lib/gettext/tools/msgcat.rb:238 ../lib/gettext/tools/msgmerge.rb:370
71
+ #: ../lib/gettext/tools/msgcat.rb:238 ../lib/gettext/tools/msgmerge.rb:375
72
72
  msgid "It is same as --sort-by-msgid"
73
73
  msgstr ""
74
74
 
@@ -96,11 +96,11 @@ msgstr ""
96
96
  msgid "Remove all comments"
97
97
  msgstr ""
98
98
 
99
- #: ../lib/gettext/tools/msgcat.rb:274 ../lib/gettext/tools/msgmerge.rb:398 ../lib/gettext/tools/xgettext.rb:312
99
+ #: ../lib/gettext/tools/msgcat.rb:274 ../lib/gettext/tools/msgmerge.rb:403 ../lib/gettext/tools/xgettext.rb:312
100
100
  msgid "Set output page width"
101
101
  msgstr ""
102
102
 
103
- #: ../lib/gettext/tools/msgcat.rb:280 ../lib/gettext/tools/msgmerge.rb:404 ../lib/gettext/tools/xgettext.rb:318
103
+ #: ../lib/gettext/tools/msgcat.rb:280 ../lib/gettext/tools/msgmerge.rb:409 ../lib/gettext/tools/xgettext.rb:318
104
104
  msgid "Break long message lines, longer than the output page width, into several lines"
105
105
  msgstr ""
106
106
 
@@ -112,7 +112,7 @@ msgstr ""
112
112
  msgid "Don't report warning messages"
113
113
  msgstr ""
114
114
 
115
- #: ../lib/gettext/tools/msgcat.rb:301 ../lib/gettext/tools/msgmerge.rb:421
115
+ #: ../lib/gettext/tools/msgcat.rb:301 ../lib/gettext/tools/msgmerge.rb:426
116
116
  msgid "Don't output obsolete entries"
117
117
  msgstr ""
118
118
 
@@ -177,7 +177,7 @@ msgstr ""
177
177
  msgid "Use EMAIL as translator email address"
178
178
  msgstr ""
179
179
 
180
- #: ../lib/gettext/tools/msginit.rb:131 ../lib/gettext/tools/msgmerge.rb:425
180
+ #: ../lib/gettext/tools/msginit.rb:131 ../lib/gettext/tools/msgmerge.rb:430
181
181
  msgid "Display this help and exit"
182
182
  msgstr ""
183
183
 
@@ -212,32 +212,32 @@ msgstr ""
212
212
  msgid "Please enter your email address"
213
213
  msgstr ""
214
214
 
215
- #: ../lib/gettext/tools/msgmerge.rb:345
215
+ #: ../lib/gettext/tools/msgmerge.rb:350
216
216
  msgid "Usage: %s [OPTIONS] definition.po reference.pot"
217
217
  msgstr ""
218
218
 
219
- #: ../lib/gettext/tools/msgmerge.rb:348
219
+ #: ../lib/gettext/tools/msgmerge.rb:353
220
220
  #, fuzzy
221
221
  msgid "Merges two Uniforum style .po files together. The definition.po file is an existing PO file with translations. The reference.pot file is the last created PO file with up-to-date source references. The reference.pot is generally created by rxgettext."
222
222
  msgstr "合併兩同樣形式的 po 檔, def.po 檔是原來有翻譯的檔案,ref.pot 檔是經過原始碼更新過的新檔,ref.pot 一般是由rgettext 建立。"
223
223
 
224
- #: ../lib/gettext/tools/msgmerge.rb:359
224
+ #: ../lib/gettext/tools/msgmerge.rb:364
225
225
  msgid "Update definition.po"
226
226
  msgstr ""
227
227
 
228
- #: ../lib/gettext/tools/msgmerge.rb:393 ../lib/gettext/tools/xgettext.rb:307
228
+ #: ../lib/gettext/tools/msgmerge.rb:398 ../lib/gettext/tools/xgettext.rb:307
229
229
  msgid "Preserve '#: FILENAME:LINE' lines"
230
230
  msgstr ""
231
231
 
232
- #: ../lib/gettext/tools/msgmerge.rb:415
232
+ #: ../lib/gettext/tools/msgmerge.rb:420
233
233
  msgid "Disable fuzzy matching"
234
234
  msgstr ""
235
235
 
236
- #: ../lib/gettext/tools/msgmerge.rb:416
236
+ #: ../lib/gettext/tools/msgmerge.rb:421
237
237
  msgid "(enable)"
238
238
  msgstr ""
239
239
 
240
- #: ../lib/gettext/tools/msgmerge.rb:431
240
+ #: ../lib/gettext/tools/msgmerge.rb:436
241
241
  #, fuzzy
242
242
  msgid "Display version information and exit"
243
243
  msgstr "秀出版本資訊後退出"
@@ -285,6 +285,18 @@ msgstr "bonjour"
285
285
  assert_equal("fuzzy", merged_po["hello"].flag)
286
286
  end
287
287
 
288
+ def test_fuzzy_matching_included_source
289
+ base_msgid = "hello"
290
+ new_msgid = base_msgid + ("!" * 10)
291
+ @po[base_msgid] = "bonjour"
292
+ @pot[new_msgid] = ""
293
+ merged_po = merge
294
+
295
+ puts merged_po
296
+ assert_equal("bonjour", merged_po[new_msgid].msgstr)
297
+ assert_equal("fuzzy", merged_po[new_msgid].flag)
298
+ end
299
+
288
300
  def test_merged_entry_from_fuzzy_entry
289
301
  @po["hello"] = generate_entry(:msgid => "hello",
290
302
  :msgstr => "bonjuor",
@@ -411,7 +423,7 @@ msgid "Hello"
411
423
  msgstr ""
412
424
 
413
425
  #: hello.rb:3
414
- msgid "Hello World"
426
+ msgid "Good-bye"
415
427
  msgstr ""
416
428
  EOP
417
429
  end
@@ -462,7 +474,7 @@ msgid "World"
462
474
  msgstr "Translated World"
463
475
 
464
476
  #: hello.rb:3
465
- msgid "Hello World"
477
+ msgid "Good-bye"
466
478
  msgstr ""
467
479
  EOP
468
480
  end
@@ -493,7 +505,7 @@ msgid "World"
493
505
  msgstr "Translated World"
494
506
 
495
507
  #: hello.rb:3
496
- msgid "Hello World"
508
+ msgid "Good-bye"
497
509
  msgstr ""
498
510
  PO
499
511
  end
@@ -514,7 +526,7 @@ msgid "World"
514
526
  msgstr "Translated World"
515
527
 
516
528
  #: hello.rb:3
517
- msgid "Hello World"
529
+ msgid "Good-bye"
518
530
  msgstr ""
519
531
  PO
520
532
  end
@@ -525,12 +537,12 @@ msgstr ""
525
537
  @po_file_path, @pot_file_path)
526
538
  assert_equal(<<-PO, File.read(@po_file_path))
527
539
  #{po_header(@pot_formatted_time, @po_formatted_time)}
528
- #: hello.rb:1
529
- msgid "Hello"
540
+ #: hello.rb:3
541
+ msgid "Good-bye"
530
542
  msgstr ""
531
543
 
532
- #: hello.rb:3
533
- msgid "Hello World"
544
+ #: hello.rb:1
545
+ msgid "Hello"
534
546
  msgstr ""
535
547
 
536
548
  #: hello.rb:2
@@ -554,7 +566,7 @@ msgid "World"
554
566
  msgstr "Translated World"
555
567
 
556
568
  #: hello.rb:3
557
- msgid "Hello World"
569
+ msgid "Good-bye"
558
570
  msgstr ""
559
571
  PO
560
572
  end
@@ -574,7 +586,7 @@ msgid "World"
574
586
  msgstr "Translated World"
575
587
 
576
588
  #: hello.rb:3
577
- msgid "Hello World"
589
+ msgid "Good-bye"
578
590
  msgstr ""
579
591
  PO
580
592
  end
@@ -585,12 +597,12 @@ msgstr ""
585
597
  @po_file_path, @pot_file_path)
586
598
  assert_equal(<<-PO, File.read(@po_file_path))
587
599
  #{po_header(@pot_formatted_time, @po_formatted_time)}
588
- #: hello.rb:1
589
- msgid "Hello"
600
+ #: hello.rb:3
601
+ msgid "Good-bye"
590
602
  msgstr ""
591
603
 
592
- #: hello.rb:3
593
- msgid "Hello World"
604
+ #: hello.rb:1
605
+ msgid "Hello"
594
606
  msgstr ""
595
607
 
596
608
  #: hello.rb:2
@@ -616,7 +628,7 @@ msgid "World"
616
628
  msgstr "Translated World"
617
629
 
618
630
  #: hello.rb:3
619
- msgid "Hello World"
631
+ msgid "Good-bye"
620
632
  msgstr ""
621
633
  PO
622
634
  end
@@ -633,7 +645,7 @@ msgstr ""
633
645
  msgid "World"
634
646
  msgstr "Translated World"
635
647
 
636
- msgid "Hello World"
648
+ msgid "Good-bye"
637
649
  msgstr ""
638
650
  PO
639
651
  end
@@ -647,7 +659,7 @@ msgid "Hello very long line! This line is very long. Yes! This line is very long
647
659
  msgstr ""
648
660
 
649
661
  #: hello.rb:3
650
- msgid "Hello World"
662
+ msgid "Good-bye"
651
663
  msgstr ""
652
664
  POT
653
665
  end
@@ -655,8 +667,8 @@ msgstr ""
655
667
  def po_content
656
668
  <<-PO
657
669
  #: hello.rb:3
658
- msgid "Hello World"
659
- msgstr "Translated Hello World. This translation is very long. Yes! Very long translation!!!"
670
+ msgid "Good-bye"
671
+ msgstr "Translated Good-bye. This translation is very long. Yes! Very long translation!!!"
660
672
  PO
661
673
  end
662
674
 
@@ -671,10 +683,10 @@ msgid ""
671
683
  msgstr ""
672
684
 
673
685
  #: hello.rb:3
674
- msgid "Hello World"
686
+ msgid "Good-bye"
675
687
  msgstr ""
676
- "Translated Hello World. This translation is very long. Yes! Very long translat"
677
- "ion!!!"
688
+ "Translated Good-bye. This translation is very long. Yes! Very long translation"
689
+ "!!!"
678
690
  PO
679
691
  end
680
692
 
@@ -690,10 +702,10 @@ msgid ""
690
702
  msgstr ""
691
703
 
692
704
  #: hello.rb:3
693
- msgid "Hello World"
705
+ msgid "Good-bye"
694
706
  msgstr ""
695
- "Translated Hello World. This translation is very long. Yes! Very long "
696
- "translation!!!"
707
+ "Translated Good-bye. This translation is very long. Yes! Very long tra"
708
+ "nslation!!!"
697
709
  PO
698
710
  end
699
711
 
@@ -707,8 +719,8 @@ msgid "Hello very long line! This line is very long. Yes! This line is very long
707
719
  msgstr ""
708
720
 
709
721
  #: hello.rb:3
710
- msgid "Hello World"
711
- msgstr "Translated Hello World. This translation is very long. Yes! Very long translation!!!"
722
+ msgid "Good-bye"
723
+ msgstr "Translated Good-bye. This translation is very long. Yes! Very long translation!!!"
712
724
  PO
713
725
  end
714
726
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gettext
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.9
4
+ version: 3.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kouhei Sutou
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-12-30 00:00:00.000000000 Z
12
+ date: 2015-12-31 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: locale
@@ -146,10 +146,10 @@ email:
146
146
  - mutomasa at gmail.com
147
147
  executables:
148
148
  - rmsginit
149
- - rmsgcat
150
149
  - rmsgfmt
151
- - rmsgmerge
150
+ - rmsgcat
152
151
  - rxgettext
152
+ - rmsgmerge
153
153
  extensions: []
154
154
  extra_rdoc_files: []
155
155
  files:
@@ -1677,18 +1677,18 @@ signing_key:
1677
1677
  specification_version: 4
1678
1678
  summary: Gettext is a pure Ruby libary and tools to localize messages.
1679
1679
  test_files:
1680
- - test/test_po.rb
1681
- - test/test_po_parser.rb
1682
- - test/test_text_domain.rb
1683
- - test/test_gettext.rb
1684
- - test/test_string.rb
1685
- - test/test_text_domain_toplevel.rb
1686
- - test/test_class_info.rb
1680
+ - test/test_locale_path.rb
1687
1681
  - test/test_parser.rb
1688
- - test/test_thread.rb
1682
+ - test/test_class_info.rb
1683
+ - test/test_text_domain_toplevel.rb
1684
+ - test/test_po_entry.rb
1685
+ - test/test_text_domain.rb
1689
1686
  - test/test_mo.rb
1687
+ - test/test_string.rb
1688
+ - test/test_po.rb
1689
+ - test/test_gettext.rb
1690
1690
  - test/test_text_domain_bind.rb
1691
+ - test/test_thread.rb
1691
1692
  - test/test_text_domain_multi.rb
1692
- - test/test_locale_path.rb
1693
- - test/test_po_entry.rb
1693
+ - test/test_po_parser.rb
1694
1694
  has_rdoc: