@@ -, +, @@ into {lang} directory tree during translation process --- misc/translator/translate | 15 ++++++++++++++- 1 files changed, 14 insertions(+), 1 deletions(-) --- a/misc/translator/translate +++ a/misc/translator/translate @@ -25,7 +25,7 @@ use warnings; use LangInstaller; use Getopt::Long; use Pod::Usage; - +use File::Copy; my $verbose = 0; my $pref = 0; @@ -68,6 +68,19 @@ else { usage(); } +# Copy of the translated columns.def +# name expected (for example with fr-FR): columns.def.fr-FR +my $filetobecopied = C4::Context->config('intrahtdocs') . "/prog/en/columns.def.$lang"; +my $newfile = C4::Context->config('intrahtdocs') . "/prog/$lang/columns.def"; +print "Looking for the following column.def file : " . $filetobecopied . "\n"; +if (-e $filetobecopied) { + print "Language specific column.def file found.\n"; + print "Copying to destination : " . $newfile . "\n"; + copy($filetobecopied, $newfile) or die "ERROR: File cannot be copied.\n"; +} +else { + print "Language specific column.def file NOT found.\n"; +} =head1 NAME --