{"thread":{"id":"25082","subject":"[PATCH 1/2] Command names should not be translated.","startedAt":"2010-09-12T20:09:55Z","lastAt":"2010-09-13T05:07:58Z","messageCount":3,"participants":["Peter Krefting","Ævar Arnfjörð Bjarmason"],"isPatch":true,"patchVersion":1,"patchTotal":2},"messages":[{"id":"150554","messageId":"20100912202105.DA51D2FC00@perkele","threadId":"25082","inReplyTo":null,"subject":"[PATCH 1/2] Command names should not be translated.","fromName":"Peter Krefting","fromEmail":"peter@softwolves.pp.se","sentAt":"2010-09-12T20:09:55Z","receivedAt":"2010-09-12T20:09:55Z","isPatch":true,"sender":{"key":"peter@softwolves.pp.se","avatar":"https://avatars.githubusercontent.com/u/990764?v=4"},"body":"Signed-off-by: Peter Krefting <peter@softwolves.pp.se>\n---\n builtin/notes.c |   12 ++++++------\n wt-status.c     |    4 ++--\n 2 files changed, 8 insertions(+), 8 deletions(-)\n\ndiff --git a/builtin/notes.c b/builtin/notes.c\nindex e33e39a..6679322 100644\n--- a/builtin/notes.c\n+++ b/builtin/notes.c\n@@ -502,7 +502,7 @@ static int list(int argc, const char **argv, const char *prefix)\n \t\tusage_with_options(git_notes_list_usage, options);\n \t}\n \n-\tt = init_notes_check(N_(\"list\"));\n+\tt = init_notes_check(\"list\");\n \tif (argc) {\n \t\tif (get_sha1(argv[0], object))\n \t\t\tdie(_(\"Failed to resolve '%s' as a valid ref.\"), argv[0]);\n@@ -559,7 +559,7 @@ static int add(int argc, const char **argv, const char *prefix)\n \tif (get_sha1(object_ref, object))\n \t\tdie(_(\"Failed to resolve '%s' as a valid ref.\"), object_ref);\n \n-\tt = init_notes_check(N_(\"add\"));\n+\tt = init_notes_check(\"add\");\n \tnote = get_note(t, object);\n \n \tif (note) {\n@@ -635,7 +635,7 @@ static int copy(int argc, const char **argv, const char *prefix)\n \tif (get_sha1(object_ref, object))\n \t\tdie(_(\"Failed to resolve '%s' as a valid ref.\"), object_ref);\n \n-\tt = init_notes_check(N_(\"copy\"));\n+\tt = init_notes_check(\"copy\");\n \tnote = get_note(t, object);\n \n \tif (note) {\n@@ -751,7 +751,7 @@ static int show(int argc, const char **argv, const char *prefix)\n \tif (get_sha1(object_ref, object))\n \t\tdie(_(\"Failed to resolve '%s' as a valid ref.\"), object_ref);\n \n-\tt = init_notes_check(N_(\"show\"));\n+\tt = init_notes_check(\"show\");\n \tnote = get_note(t, object);\n \n \tif (!note)\n@@ -788,7 +788,7 @@ static int remove_cmd(int argc, const char **argv, const char *prefix)\n \tif (get_sha1(object_ref, object))\n \t\tdie(_(\"Failed to resolve '%s' as a valid ref.\"), object_ref);\n \n-\tt = init_notes_check(N_(\"remove\"));\n+\tt = init_notes_check(\"remove\");\n \n \tretval = remove_note(t, object);\n \tif (retval)\n@@ -822,7 +822,7 @@ static int prune(int argc, const char **argv, const char *prefix)\n \t\tusage_with_options(git_notes_prune_usage, options);\n \t}\n \n-\tt = init_notes_check(N_(\"prune\"));\n+\tt = init_notes_check(\"prune\");\n \n \tprune_notes(t, (verbose ? NOTES_PRUNE_VERBOSE : 0) |\n \t\t(show_only ? NOTES_PRUNE_VERBOSE|NOTES_PRUNE_DRYRUN : 0) );\ndiff --git a/wt-status.c b/wt-status.c\nindex f6946e1..7d4719f 100644\n--- a/wt-status.c\n+++ b/wt-status.c\n@@ -663,9 +663,9 @@ void wt_status_print(struct wt_status *s)\n \t\twt_status_print_submodule_summary(s, 1);  /* unstaged */\n \t}\n \tif (s->show_untracked_files) {\n-\t\twt_status_print_other(s, &s->untracked, _(\"Untracked\"), _(\"add\"));\n+\t\twt_status_print_other(s, &s->untracked, _(\"Untracked\"), \"add\");\n \t\tif (s->show_ignored_files)\n-\t\t\twt_status_print_other(s, &s->ignored, _(\"Ignored\"), _(\"add -f\"));\n+\t\t\twt_status_print_other(s, &s->ignored, _(\"Ignored\"), \"add -f\");\n \t} else if (s->commitable)\n \t\tfprintf(s->fp, _(\"# Untracked files not listed%s\\n\"),\n \t\t\tadvice_status_hints\n-- \n1.7.1\n"},{"id":"150565","messageId":"AANLkTinN_fDAVVuT1ygCe7gMpHqAhL4GGjrZ98igbbP3@mail.gmail.com","threadId":"25082","inReplyTo":"20100912202105.DA51D2FC00@perkele","subject":"Re: [PATCH 1/2] Command names should not be translated.","fromName":"Ævar Arnfjörð Bjarmason","fromEmail":"avarab@gmail.com","sentAt":"2010-09-12T22:51:54Z","receivedAt":"2010-09-12T22:51:54Z","isPatch":true,"sender":{"key":"avarab@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45301?v=4"},"body":"On Sun, Sep 12, 2010 at 20:09, Peter Krefting <peter@softwolves.pp.se> wrote:\n\nFirst off, thanks for contributing to this.\n\n> -       t = init_notes_check(N_(\"list\"));\n> +       t = init_notes_check(\"list\");\n> -       t = init_notes_check(N_(\"add\"));\n> +       t = init_notes_check(\"add\");\n> -       t = init_notes_check(N_(\"copy\"));\n> +       t = init_notes_check(\"copy\");\n> -       t = init_notes_check(N_(\"show\"));\n> +       t = init_notes_check(\"show\");\n> -       t = init_notes_check(N_(\"remove\"));\n> +       t = init_notes_check(\"remove\");\n> -       t = init_notes_check(N_(\"prune\"));\n> +       t = init_notes_check(\"prune\");\n\nI disagree with all those. These don't end up being used in a context like:\n\n    die(\"git-%s: error ...\", command);\n\nBut:\n\n    die(_(\"Refusing to %s notes in %s (outside of refs/notes/)\"),\n        _(subcommand), t->ref);\n\nI.e. here the git notes command name should be translated as a verb in\nthe native language (or not, that's up to the translator). E.g. I'd\ntranslate that as:\n\n    add: Neita að bæta við\n    copy: Neita að afrita\n\netc. into Icelandic. Other languages will probably also want to\ntranslate that.\n\n>        prune_notes(t, (verbose ? NOTES_PRUNE_VERBOSE : 0) |\n>                (show_only ? NOTES_PRUNE_VERBOSE|NOTES_PRUNE_DRYRUN : 0) );\n> diff --git a/wt-status.c b/wt-status.c\n> index f6946e1..7d4719f 100644\n> --- a/wt-status.c\n> +++ b/wt-status.c\n> @@ -663,9 +663,9 @@ void wt_status_print(struct wt_status *s)\n>                wt_status_print_submodule_summary(s, 1);  /* unstaged */\n>        }\n>        if (s->show_untracked_files) {\n> -               wt_status_print_other(s, &s->untracked, _(\"Untracked\"), _(\"add\"));\n> +               wt_status_print_other(s, &s->untracked, _(\"Untracked\"), \"add\");\n>                if (s->show_ignored_files)\n> -                       wt_status_print_other(s, &s->ignored, _(\"Ignored\"), _(\"add -f\"));\n> +                       wt_status_print_other(s, &s->ignored, _(\"Ignored\"), \"add -f\");\n>        } else if (s->commitable)\n>                fprintf(s->fp, _(\"# Untracked files not listed%s\\n\"),\n>                        advice_status_hints\n\nThese however are good, because here it gets used as:\n\n    color_fprintf_ln(s->fp, c, _(\"#   (use \\\"git %s <file>...\\\" to\ninclude in what will be committed)\"), how);\n\nI.e. this is purely a hardcoded command name.\n"},{"id":"150571","messageId":"alpine.DEB.2.00.1009130706450.29710@perkele.intern.softwolves.pp.se","threadId":"25082","inReplyTo":"AANLkTinN_fDAVVuT1ygCe7gMpHqAhL4GGjrZ98igbbP3@mail.gmail.com","subject":"Re: [PATCH 1/2] Command names should not be translated.","fromName":"Peter Krefting","fromEmail":"peter@softwolves.pp.se","sentAt":"2010-09-13T05:07:58Z","receivedAt":"2010-09-13T05:07:58Z","isPatch":true,"sender":{"key":"peter@softwolves.pp.se","avatar":"https://avatars.githubusercontent.com/u/990764?v=4"},"body":"Ævar Arnfjörð Bjarmason:\n\n> I disagree with all those. These don't end up being used in a context like:\n>\n>    die(\"git-%s: error ...\", command);\n>\n> But:\n>\n>    die(_(\"Refusing to %s notes in %s (outside of refs/notes/)\"),\n>        _(subcommand), t->ref);\n\nYou are right. I saw the first as a duplicate source of the wt-status.c \ncommand name that I got for translation. Drop these, then.\n\nStill the construct is a bit awkward, but possibly doable, at least for my \nlanguage.\n\n> These however are good, because here it gets used as:\n>\n>    color_fprintf_ln(s->fp, c, _(\"#   (use \\\"git %s <file>...\\\" to\n> include in what will be committed)\"), how);\n>\n> I.e. this is purely a hardcoded command name.\n\nIndeed.\n\n-- \n\\\\// Peter - http://www.softwolves.pp.se/\n"}]}