XGETTEXT-TT2(1p)

πŸ“¦
version 1.0 Β· 2 versions
, in debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ 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:1
  • ngettext:1,2
  • pgettext:1c,2
  • gettextp:1,2c
  • npgettext:1c,2,3
  • ngettextp:1,2,3c
  • xgettext:1
  • nxgettext:1,2
  • pxgettext:1c,2
  • xgettextp:1,2c
  • npxgettext:1c,2,3
  • nxgettextp: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-format
  • nxgettext:1:perl-brace-format
  • nxgettext:2:perl-brace-format
  • pxgettext:2:perl-brace-format
  • xgettextp:1:perl-brace-format
  • npxgettext:2:perl-brace-format
  • npxgettext:3:perl-brace-format
  • nxgettextp:1:perl-brace-format
  • nxgettextp:2:perl-brace-format

look at all those perl-brace-formats. it's a whole aesthetic πŸ“


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:

  • Template
  • Locale::XGettext
  • Template::Plugin::Gettext
  • xgettext
  • perl

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 🧚✨