Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Here is a rough French translation. It is not great as my technical French is getting quite poor as I use mostly English these days ;--( and as I don't use any French software.

As a general comment I am afraid you are being a little too clever here. The order of words in a sentence vary between languages, and it is very difficult, if not right down impossible, to generate sentences from bits and pieces like you do. Usually if you want your software to be easily ported to other languages each message (or at least each sentence) has to be a separate string. A common trickis to use sprintf in order not to depend on the original English order:

"$format config copied to $tftpserver from $args->{h} by $user\n"

becomes:

sprintf "config copied to %s from %s by %s\n", $tftpserver, $args->{h}, $user;

(note that $args->{h} will not be interpolated properly in the string by the way)

And in French:

sprintf "configuration de %s copiée sur %s par %s\n", $tftpserver, $args->{h}, $user;

Note that if you want to be able to change the order of parameters you will need to add yet an other indirection layer, for example the message could be stored as "configuration de $par{server} copiée sur $par{target} par $par{user}\n" and the output being done by a sub that gets passed the parameters as a hash.

Anyway, here is the translation, which will certainly be corrected by other Mongueurs.

$lang{flag_req} = "Pancho: Options manquantes" $lang{run_help} = "Entrer $0 --help"; $lang{no_open} = "Impossible d'ouvrir le fichier spé +cifié par --li"; $lang{chk_path} = "Veuilliez vérifier le chemin et l' +existence du fichier"; # I don't know if 'noeud' is the proper translation for 'node +' here $lang{no_nodes} = "Vous n'avez pas spécifié un noeud +ou une liste de noeuds cible"; $lang{no_snmp} = "Vous n'avez pas spécifié une commu +nauté SNMP."; $lang{no_tftp} = "Vous n'avez pas spécifié un serveu +r tftp."; # The adjective comes after the noum in French, so you can't +have a hanging 'remote' $lang{exp_tftp} = "Pour tftp une configuration"; $lang{no_file} = "Vous devez spécifier un nom de fic +hier avec l'option -f"; # 'telecharger' means both upload and downlod in French :--( $lang{no_updown} = "Impossible d'uploader et de telech +arger en meme temps"; $lang{version} = "Pancho version"; $lang{no_log} = "Impossible d'ouvrir le fichier log +"; $lang{exp_path} = "Veuillez vérifier le chemin"; # we're starting to hit problems here, the syntax does not ma +tch $lang{copy_start} = "Copie de la configuration de et ve +rs startup-c"; $lang{no_catos} = "impossible avec CatOS."; $lang{no_depmib} = "impossible avec mibs (obsoléte)."; + # it should be a e` (è here) $lang{cp_success} = "Copie effectuée vers"; # this rarely works $lang{on} = "sur"; $lang{from} = "de"; $lang{to} = "vers"; $lang{by} = "par"; $lang{cp_from} = "copié de"; $lang{cp_to} = "copié vers"; $lang{to_nvram} = "vers nvram sur"; $lang{cp_nvram} = "copié vers nvram sur"; $lang{from_nvram} = "de nvram sur"; $lang{wr_success} = "Configuration chargée en memoire s +ur"; # it's hard to fit the originalwording in a French sentence $lang{rel_success} = "Rechargement des parametres de"; $lang{init} = "initialisation du rechargement sur +";

In reply to Re: multi-lingual support... by mirod
in thread multi-lingual support... by c

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (2)
As of 2024-04-26 01:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found