LangInstaller.pm - Handle templates and preferences translation
my $installer = LangInstaller->new( 'fr-FR' ); $installer->create(); $installer->update(); $installer->install(); for my $lang ( @{$installer->{langs} ) { $installer->set_lang( $lan ); $installer->install(); }
Create a new instance of the installer object.
For the current language, create .po files for templates and preferences based of the english ('en') version.
For the current language, update .po files.
For the current langage $self-
{lang}, use .po files to translate the english version of templates and preferences files and copy those files in the appropriate directory.
Create 4 kinds of .po files in po subdirectory: (1) one from each theme on opac pages templates, (2) intranet templates and help, (3) preferences, and (4) one for each MARC dialect.
Contains extracted text from english (en) OPAC templates found in <KOHA_ROOT>/koha-tmpl/opac-tmpl/{theme}/en/ directory.
Contains extracted text from english (en) intranet templates found in <KOHA_ROOT>/koha-tmpl/intranet-tmpl/prog/en/ directory.
Contains extracted text from english (en) preferences. They are found in files located in <KOHA_ROOT>/koha-tmpl/intranet-tmpl/prog/en/admin/preferences directory.
Contains extracted text from english (en) files from opac and intranet, related with MARC dialects.
Update .po files in po directory, named lang-*.po.