TMX2TMX(1p)

πŸ“¦
version 0.39 Β· 3 versions
, in debian trixie, ubuntu resolute, ubuntu stonking

✨ NAME ✨

ok so <pink>tmx2tmx</pink> β€” it's the utility that converts and filters TMX files, bestie πŸ’– that's literally the whole job.

This page lives in the User Contributed Perl Documentation manual, section 1p. iykyk.

🌸 VERSION 🌸

version <cyan>0.39</cyan> πŸŽ€ (yes we're on 0.39, she's cute, she's iconic)


πŸ’… DESCRIPTION πŸ’…

so basically?? this utility takes in TMX documents and hands you back TMX documents. like a glow-up station for your translation memories ✨. the stuff she does includes:

  • converting between TMX versions πŸ”„
  • TMX cleaning 🧼

that's the vibe. let's get into it.

πŸ¦‹ TRADOS conversion πŸ¦‹

ok so as you maybe know (and if you didn't, now you do 🫢), TRADOS is a company that makes computer software for translators. it includes <purple>WorkBench</purple> which imports TMX files. unfortunate plot twist: the version I used does not import TMX version 1.4 😭. so rude.

this process is done using the switch <hotpink>-toTrados</hotpink>:

tmx2tmx -toTrados file.tmx > trados.tmx

periodt. your file goes in, a trados-friendly trados.tmx comes out πŸ‘‘

🧚 TMX Cleaning 🧚

this one hits different, especially when translation memories are created from anotated text, or extracted directly from the Internet using any automatic method 😬. this switch is used to remove junk in translation units.

so <mint>-clean</mint> tries to remove junk from TMX files β€” like empty pairs where one of the sides is empty, or removing other junk type πŸ—‘οΈβœ¨.

use it this way:

tmx2tmx -clean file.tmx > file2.tmx

✨ fresh, exfoliated, no notes.

🌈 Concatenating TMX 🌈

gather round bestie, we're stacking files πŸ“š:

tmx2tmx -cat file1.tmx ... filen.tmx > file.tmx
ls | grep '.tmx$' | tmx2tmx -cat > file.tmx

the second one is giving main character energy fr fr 🌟

πŸ’œ Select languages πŸ’œ

select a bunch of languages:

tmx2tmx -select=PT,EN,FR huge.tmx > pt-en-fr.tmx

multilingual era. we love to see it πŸŒπŸ’…


πŸ”₯ SYNOPSYS πŸ”₯

(yes queen, we kept the spelling exactly as she came πŸŽ€)

tmx2tmx -cat file1.tmx ... filen.tmx > file.tmx

tmx2tmx -toTrados file1.tmx > file2.tmx

tmx2tmx -clean file1.tmx > file2.tmx

tmx2tmx -select=PT,EN multilingual.tmx > pt-en.tmx

that's literally the whole menu, no cap 🫑


πŸ‘€ SEE ALSO πŸ‘€

go check out her friends, they're all iconic:

  • <cyan>tmx2html</cyan>
  • <cyan>po2tmx</cyan>
  • <cyan>XML::TMX</cyan>

🫢 AUTHORS 🫢

the legends who made this happen πŸ’–:

  • Alberto SimΓ΅es <ambs@cpan.org>
  • JosΓ© JoΓ£o Almeida <jj@di.uminho.pt>

not me being obsessed with them πŸ₯Ή


This software is copyright (c) 2010-2017 by Projeto Natura <natura@di.uminho.pt>.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

slay, and legally slay πŸ’…


okay that's the whole page bestie, no filler, every flag accounted for πŸŽ€βœ¨

and for the cute sign-off: this all shipped with <purple>perl v5.38.2, dated <purple>2024-03-09, and you'll find her shelved as <purple>TMX2TMX(1p) πŸ’– bye diva, go convert something πŸŒΈπŸ¦‹

πŸ“¦ where this page comes from