{"thread":{"id":"30714","subject":"[GETTEXT BUG] xgettext(1) can't extract \"gettext -- foo\"","startedAt":"2012-06-05T09:05:50Z","lastAt":"2012-06-05T09:05:50Z","messageCount":1,"participants":["Ævar Arnfjörð Bjarmason"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"192883","messageId":"CACBZZX7rhA23k5Mz=dY6G_75hwBMgWbKrkAGJv4rd9URAh4vHw@mail.gmail.com","threadId":"30714","inReplyTo":null,"subject":"[GETTEXT BUG] xgettext(1) can't extract \"gettext -- foo\"","fromName":"Ævar Arnfjörð Bjarmason","fromEmail":"avarab@gmail.com","sentAt":"2012-06-05T09:05:50Z","receivedAt":"2012-06-05T09:05:50Z","isPatch":false,"sender":{"key":"avarab@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45301?v=4"},"body":"The Git project is having issues with xgettext being unable to extract\nmsgid's provided to gettext(1) where the first argument is --. Here's\na minimal testcase:\n\n    $ cat /tmp/xgettext-tesh.sh\n    #!/bin/sh\n    . gettext.sh\n    gettext \"hello \"\n    gettext -- \"world\"\n    echo\n\nIf that's extracted with xgettext(1) the message on line 4 is presumed\nto be \"--\", when in fact it should be \"world\":\n\n    $ xgettext --omit-header --force-po --output=/tmp/xgettext.po\n--language=Shell --debug /tmp/xgettext-tesh.sh ; cat /tmp/xgettext.po\n    #: /tmp/xgettext-tesh.sh:3\n    msgid \"hello \"\n    msgstr \"\"\n\n    #: /tmp/xgettext-tesh.sh:4\n    msgid \"--\"\n    msgstr \"\"\n\nThere's currently a proposed patch to hack around this using something\nlike:\n\n    gitgettext () {\n       gettext -- \"$1\"\n       echo\n    }\n\nIs there a better way to handle this, and is this a bug the gettext\nproject is aware of and might be fixing sometime soon?\n"}]}