Fork me on GitHub

gettext:gettext

Full name:

de.fenvariel:gettext-maven-plugin:2.0.0:gettext

Description:

Invokes xgettext to extract messages from source code and store them in the keys.pot file.

Attributes:

  • Requires a Maven project to be executed.
  • Binds by default to the lifecycle phase: generate-resources.

Required Parameters

Name Type Since Description
<encoding> String - The encoding of the source Java files. utf-8 is a superset of ascii.
Default value is: utf-8.
<keysFile> String - Filename of the .pot file.
Default value is: keys.pot.
<keywords> String - The keywords the xgettext parser will look for to extract messages. The default value works with libraries that use the _-format method, as recommended by Gettext documentation.
Default value is: -k_ -k_n1,2.
<outputDirectory> File - The output directory for generated class or properties files.
User property is: project.build.outputDirectory.
<poDirectory> File - The output directory for the keys.pot directory for merging .po files.
Default value is: ${basedir}/src/main/po.
<sourceDirectory> File - Source directory. This directory is searched recursively for .java files.
User property is: project.build.sourceDirectory.
<xgettextCmd> String - The xgettext command.
Default value is: xgettext.

Optional Parameters

Name Type Since Description
<copyrightHolder> String - Set the copyright holder in the output. string should be the copyright holder of the surrounding package. (Note that the msgstr strings, extracted from the package's sources, belong to the copyright holder of the package.) Translators are expected to transfer or disclaim the copyright for their translations, so that package maintainers can distribute them without legal risk. If string is empty, the output files are marked as being in the public domain; in this case, the translators are expected to disclaim their copyright, again so that package maintainers can distribute them without legal risk. The default value for string is the '' so public domain.
User property is: project.organisation.name.
<extraArguments> String[] - Optional raw command line arguments
<extraSourceFiles> FileSet -
<joinExisting> boolean - (no description)
Default value is: false.
<location> Location - set the location comment-mode (full,file,.
<msgidBugsAddress> String - Set the reporting address for msgid bugs. This is the email address or URL to which the translators shall report bugs in the untranslated strings: - Strings which are not entire sentences; see the maintainer guidelines in Preparing Strings. - Strings which use unclear terms or require additional context to be understood. - Strings which make invalid assumptions about notation of date, time or money. - Pluralisation problems. - Incorrect English spelling. - Incorrect formatting. It can be your email address, or a mailing list address where translators can write to without being subscribed, or the URL of a web page through which the translators can contact you. The default value is empty, which means that translators will be clueless! Don't forget to specify this option.
<omitHeader> boolean - (no description)
Default value is: false.
<packageName> String - Set the package name in the header of the output.
User property is: project.build.finalName.
<packageVersion> String - Set the package version in the header of the output. This option has an effect only if the 'packageName' option is also used.
User property is: project.version.
<sort> Sort - Set if the output should be sorted.
Default value is: FALSE.

Parameter Details

<copyrightHolder>

Set the copyright holder in the output. string should be the copyright holder of the surrounding package. (Note that the msgstr strings, extracted from the package's sources, belong to the copyright holder of the package.) Translators are expected to transfer or disclaim the copyright for their translations, so that package maintainers can distribute them without legal risk. If string is empty, the output files are marked as being in the public domain; in this case, the translators are expected to disclaim their copyright, again so that package maintainers can distribute them without legal risk. The default value for string is the '' so public domain.
  • Type: java.lang.String
  • Required: No
  • User Property: project.organisation.name

<encoding>

The encoding of the source Java files. utf-8 is a superset of ascii.
  • Type: java.lang.String
  • Required: Yes
  • Default: utf-8

<extraArguments>

Optional raw command line arguments
  • Type: java.lang.String[]
  • Required: No

<extraSourceFiles>

  • Type: org.apache.maven.model.FileSet
  • Required: No

<joinExisting>

(no description)
  • Type: boolean
  • Required: No
  • Default: false

<keysFile>

Filename of the .pot file.
  • Type: java.lang.String
  • Required: Yes
  • Default: keys.pot

<keywords>

The keywords the xgettext parser will look for to extract messages. The default value works with libraries that use the _-format method, as recommended by Gettext documentation.
  • Type: java.lang.String
  • Required: Yes
  • Default: -k_ -k_n1,2

<location>

set the location comment-mode (full,file,.
  • Type: de.fenvariel.maven.gettext.Location
  • Required: No

<msgidBugsAddress>

Set the reporting address for msgid bugs. This is the email address or URL to which the translators shall report bugs in the untranslated strings: - Strings which are not entire sentences; see the maintainer guidelines in Preparing Strings. - Strings which use unclear terms or require additional context to be understood. - Strings which make invalid assumptions about notation of date, time or money. - Pluralisation problems. - Incorrect English spelling. - Incorrect formatting. It can be your email address, or a mailing list address where translators can write to without being subscribed, or the URL of a web page through which the translators can contact you. The default value is empty, which means that translators will be clueless! Don't forget to specify this option.
  • Type: java.lang.String
  • Required: No

<omitHeader>

(no description)
  • Type: boolean
  • Required: No
  • Default: false

<outputDirectory>

The output directory for generated class or properties files.
  • Type: java.io.File
  • Required: Yes
  • User Property: project.build.outputDirectory

<packageName>

Set the package name in the header of the output.
  • Type: java.lang.String
  • Required: No
  • User Property: project.build.finalName

<packageVersion>

Set the package version in the header of the output. This option has an effect only if the 'packageName' option is also used.
  • Type: java.lang.String
  • Required: No
  • User Property: project.version

<poDirectory>

The output directory for the keys.pot directory for merging .po files.
  • Type: java.io.File
  • Required: Yes
  • Default: ${basedir}/src/main/po

<sort>

Set if the output should be sorted.
  • Type: de.fenvariel.maven.gettext.Sort
  • Required: No
  • Default: FALSE

<sourceDirectory>

Source directory. This directory is searched recursively for .java files.
  • Type: java.io.File
  • Required: Yes
  • User Property: project.build.sourceDirectory

<xgettextCmd>

The xgettext command.
  • Type: java.lang.String
  • Required: Yes
  • Default: xgettext