1Publican::Translate(3)User Contributed Perl DocumentationPublican::Translate(3)
2
3
4

NAME

6       Publican::Translate - Module for manipulating POT and PO files.
7

SYNOPSIS

9               use Publican::Translate;
10               my $po = Publican::Translate->new();
11
12               $po->update_pot();
13               $po->update_po({ langs => 'fr-FR,de-DE' });
14               $po->update_po({ langs => 'all' });
15               $po->merge_xml({ lang  => 'fr-FR' });
16

DESCRIPTION

18       Creates, updates and merges POT and PO files for Publican projects.
19

INTERFACE

21   new
22       Create a new Publican::Translate object.
23
24   trans_drop
25       Snapshot the source to give translation a stable base.
26
27   update_pot
28       Update the pot files
29
30   po2xml
31       Merge XML and PO into a translated XML file.
32
33   update_po
34       Update the PO files using internal process or msgmerge
35
36   merge_po
37       Merge updated POT files in to existing PO files.
38
39   match_strings
40       Compare 2 strings and return how closely they match.
41
42       Returns a vlaue between 0 and 1, weighted for string length.
43
44   update_po_all
45       Update the PO files for all languages
46
47   get_msgs
48       Get the strings to translate from an XML::TreeBuilder object
49
50   merge_msgs
51       Merge translations in to XML
52
53   translate
54       Replace strings with translated strings.
55
56   print_msgs
57       Print the translation strings in an XML::TreeBuilder object to a POT
58       file
59
60   header
61       Returns a valid PO header string.
62
63   detag
64       Format a string for use in a PO file.
65
66   po_report
67       Generate translation statistics for the supplied language.
68

DIAGNOSTICS

70       "unknown args %s"
71           All subs with named parameters will return this error when
72           unexpected named arguments are provided.
73
74       "%s is a required argument"
75           Any sub with a mandatory parameter will return this error if the
76           parameter is undef.
77

CONFIGURATION AND ENVIRONMENT

79       Publican requires no configuration files or environment variables.
80

DEPENDENCIES

82       Carp version Publican File::Path Term::ANSIColor DateTime Locale::PO
83       XML::TreeBuilder String::Similarity
84

INCOMPATIBILITIES

86       None reported.
87

BUGS AND LIMITATIONS

89       No bugs have been reported.
90
91       Please report any bugs or feature requests to
92       "publican-list@redhat.com", or through the web interface at
93       <https://bugzilla.redhat.com/bugzilla/enter_bug.cgi?product=Publican&amp;component=publican>.
94

AUTHOR

96       Jeff Fearn  "<jfearn@redhat.com>"
97
98
99
100perl v5.36.1                      2023-11-22            Publican::Translate(3)
Impressum