{
    "mode": "man",
    "parameter": "msginit",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/msginit/1/json",
    "generated": "2026-06-16T06:08:35Z",
    "synopsis": "msginit [OPTION]",
    "sections": {
        "NAME": {
            "content": "msginit - initialize a message catalog\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "msginit [OPTION]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "Creates a new PO file, initializing the meta information with values from the user's environ-\nment.\n\nMandatory arguments to long options are mandatory for short options too.\n\nInput file location:\n-i, --input=INPUTFILE\ninput POT file\n\nIf no input file is given, the current directory is searched for the POT file.  If it  is  -,\nstandard input is read.\n\nOutput file location:\n-o, --output-file=FILE\nwrite output to specified PO file\n\nIf  no  output file is given, it depends on the --locale option or the user's locale setting.\nIf it is -, the results are written to standard output.\n\nInput file syntax:",
            "subsections": [
                {
                    "name": "-P, --properties-input",
                    "content": "input file is in Java .properties syntax\n",
                    "flag": "-P",
                    "long": "--properties-input"
                },
                {
                    "name": "--stringtable-input",
                    "content": "input file is in NeXTstep/GNUstep .strings syntax\n\nOutput details:\n-l, --locale=LLCC[.ENCODING]\nset target locale\n",
                    "long": "--stringtable-input"
                },
                {
                    "name": "--no-translator",
                    "content": "assume the PO file is automatically generated\n",
                    "long": "--no-translator"
                },
                {
                    "name": "--color",
                    "content": "use colors and other text attributes always\n\n--color=WHEN\nuse colors and other text attributes if WHEN.  WHEN may be 'always', 'never',  'auto',\nor 'html'.\n\n--style=STYLEFILE\nspecify CSS style rule file for --color\n",
                    "long": "--color"
                },
                {
                    "name": "-p, --properties-output",
                    "content": "write out a Java .properties file\n",
                    "flag": "-p",
                    "long": "--properties-output"
                },
                {
                    "name": "--stringtable-output",
                    "content": "write out a NeXTstep/GNUstep .strings file\n\n-w, --width=NUMBER\nset output page width\n",
                    "long": "--stringtable-output"
                },
                {
                    "name": "--no-wrap",
                    "content": "do not break long message lines, longer than the output page width, into several lines\n\nInformative output:",
                    "long": "--no-wrap"
                },
                {
                    "name": "-h, --help",
                    "content": "display this help and exit\n",
                    "flag": "-h",
                    "long": "--help"
                },
                {
                    "name": "-V, --version",
                    "content": "output version information and exit\n",
                    "flag": "-V",
                    "long": "--version"
                }
            ]
        },
        "AUTHOR": {
            "content": "Written by Bruno Haible.\n",
            "subsections": []
        },
        "REPORTING BUGS": {
            "content": "Report  bugs in the bug tracker at <https://savannah.gnu.org/projects/gettext> or by email to\n<bug-gettext@gnu.org>.\n",
            "subsections": []
        },
        "COPYRIGHT": {
            "content": "Copyright (C) 2001-2020 Free Software Foundation, Inc.  License GPLv3+: GNU GPL version 3  or\nlater <https://gnu.org/licenses/gpl.html>\nThis  is free software: you are free to change and redistribute it.  There is NO WARRANTY, to\nthe extent permitted by law.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "The full documentation for msginit is maintained as a Texinfo manual.  If the  info  and  ms-\nginit programs are properly installed at your site, the command\n\ninfo msginit\n\nshould give you access to the complete manual.\n\nGNU gettext-tools 0.21                      March 2022                                 MSGINIT(1)",
            "subsections": []
        }
    },
    "summary": "msginit - initialize a message catalog",
    "flags": [
        {
            "flag": "-P",
            "long": "--properties-input",
            "arg": null,
            "description": "input file is in Java .properties syntax"
        },
        {
            "flag": "",
            "long": "--stringtable-input",
            "arg": null,
            "description": "input file is in NeXTstep/GNUstep .strings syntax Output details: -l, --locale=LLCC[.ENCODING] set target locale"
        },
        {
            "flag": "",
            "long": "--no-translator",
            "arg": null,
            "description": "assume the PO file is automatically generated"
        },
        {
            "flag": "",
            "long": "--color",
            "arg": null,
            "description": "use colors and other text attributes always --color=WHEN use colors and other text attributes if WHEN. WHEN may be 'always', 'never', 'auto', or 'html'. --style=STYLEFILE specify CSS style rule file for --color"
        },
        {
            "flag": "-p",
            "long": "--properties-output",
            "arg": null,
            "description": "write out a Java .properties file"
        },
        {
            "flag": "",
            "long": "--stringtable-output",
            "arg": null,
            "description": "write out a NeXTstep/GNUstep .strings file -w, --width=NUMBER set output page width"
        },
        {
            "flag": "",
            "long": "--no-wrap",
            "arg": null,
            "description": "do not break long message lines, longer than the output page width, into several lines Informative output:"
        },
        {
            "flag": "-h",
            "long": "--help",
            "arg": null,
            "description": "display this help and exit"
        },
        {
            "flag": "-V",
            "long": "--version",
            "arg": null,
            "description": "output version information and exit"
        }
    ],
    "examples": [],
    "see_also": [],
    "tldr": {
        "source": "official",
        "description": "Generate language specific translation files based on Portable Object Templates.",
        "examples": [
            {
                "description": "Generate Portable Object files in system locale from `messages.pot`",
                "command": "msginit"
            },
            {
                "description": "Define locale to generate from a specific template",
                "command": "msginit {{-l|--locale}} {{locale}} {{-i|--input}} {{path/to/messages.pot}}"
            },
            {
                "description": "Display help",
                "command": "msginit {{-h|--help}}"
            }
        ]
    }
}