XGETTEXT-TT2(1p)
β¨ xgettext-tt2 β¨
okay so bestie, welcome to xgettext-tt2 β the little Perl script from the User Contributed Perl Documentation section (1p) that pulls translatable strings out of your Template Toolkit 2 templates. it's giving i18n, it's giving group project, and yes it's literally here to do the boring part for you π
π NAME π
xgettext-tt2 β extract translatable strings from Template Toolkit 2 templates πΈ
π¦ SYNOPSIS π¦
xgettext-tt2 [OPTIONS] INPUTFILES
xgettext-tt2 [OPTIONS] --files-from=FILELIST
like, that's it. that's the whole vibe. two ways in: hand it a bunch of INPUTFILES, or hand it a FILELIST via --files-from and let it read the list itself π
π DESCRIPTION π
so the program xgettext-tt2 extracts translatable strings from templates for the Template Toolkit version 2 (go peek at <http://www.template-toolkit.org>, it's iconic).
want the whole overview of every command line option? run this:
perldoc Locale::XGettext
or this:
man Locale::XGettext
and the online version of the manual page is right here if you'd rather scroll:
<https://github.com/gflohr/Locale-XGettext/blob/master/lib/Locale/XGettext.pod>
no gatekeeping in this household π«Ά
π DEFAULT KEYWORDS π
bestie the program comes with these built-in default keywords already loaded, and they're the ones supported by Template::Plugin::Gettext:
gettext:1ngettext:1,2pgettext:1c,2gettextp:1,2cnpgettext:1c,2,3ngettextp:1,2,3cxgettext:1nxgettext:1,2pxgettext:1c,2xgettextp:1,2cnpxgettext:1c,2,3nxgettextp:1,2,3c
twelve of them, all pre-loaded, no setup required. slay β¨
π DEFAULT KEYWORDS π
(no fr, there are two sections with this exact name in the original and i am NOT the one to edit the source material π)
the program also has these built-in default flags, supported by Template::Plugin::Gettext:
xgettext:1:perl-brace-formatnxgettext:1:perl-brace-formatnxgettext:2:perl-brace-formatpxgettext:2:perl-brace-formatxgettextp:1:perl-brace-formatnpxgettext:2:perl-brace-formatnpxgettext:3:perl-brace-formatnxgettextp:1:perl-brace-formatnxgettextp:2:perl-brace-format
look at all those perl-brace-formats. it's a whole aesthetic π
π COPYRIGHT π
Copyright (C) 2016-2018 Guido Flohr (<http://www.guido-flohr.net/>).
License LGPLv3+: GNU General Public License version 3 or later <http://gnu.org/licenses/lgpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. π like, genuinely no warranty, bestie, don't come for anyone if it breaks.
Copyright (C) 2016-2018 Guido Flohr <guido.flohr@cantanea.com>, all rights reserved.
π₯ SEE ALSO π₯
go read these next, they're the supporting cast:
TemplateLocale::XGettextTemplate::Plugin::Gettextxgettextperl
and that's the whole page, babe π this was perl v5.36.0, dated 2023-07-21, served fresh out of the User Contributed Perl Documentation, section 1p. mwah, go extract those strings, you're doing amazing π§β¨
π¦ where this page comes from
- debian trixie: libtemplate-plugin-gettext-perl 1.0-1 Β· LGPL-3.0-or-later
- ubuntu noble: libtemplate-plugin-gettext-perl 1.0-1 Β· LGPL-3.0-or-later
- ubuntu resolute: libtemplate-plugin-gettext-perl 1.0-1 Β· LGPL-3.0-or-later
- ubuntu stonking: libtemplate-plugin-gettext-perl 1.0-1 Β· LGPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms