git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH v3 03/11] i18n: turn "options are incompatible" into "cannot be used together"

From
Johannes Sixt <j6t@kdbg.org>
Date
Dec 29, 2021, 19:36 UTC
Message-ID
<233ae6c6-294f-f68c-51ca-ec83d25f05dd@kdbg.org>
In-Reply-To
<486cc6c89e2612761bc8835700c9c85c0b50ab55.1640804108.git.gitgitgadget@gmail.com>
Am 29.12.21 um 19:54 schrieb Jean-Noël Avila via GitGitGadget:
Show 28 quoted lines
> @@ -2867,24 +2867,24 @@ int setup_revisions(int argc, const char **argv, struct rev_info *revs, struct s
>  	compile_grep_patterns(&revs->grep_filter);
>  
>  	if (revs->reverse && revs->reflog_info)
> -		die("cannot combine --reverse with --walk-reflogs");
> +		die(_("options '%s' and '%s' cannot be used together"), "--reverse", "--walk-reflogs");
>  	if (revs->reflog_info && revs->limited)
>  		die("cannot combine --walk-reflogs with history-limiting options");
>  	if (revs->rewrite_parents && revs->children.name)
> -		die("cannot combine --parents and --children");
> +		die(_("options '%s' and '%s' cannot be used together"), "--parents", "--children");
>  
>  	/*
>  	 * Limitations on the graph functionality
>  	 */
>  	if (revs->reverse && revs->graph)
> -		die("cannot combine --reverse with --graph");
> +		die(_("options '%s' and '%s' cannot be used together"), "--reverse", "--graph");
>  
>  	if (revs->reflog_info && revs->graph)
> -		die("cannot combine --walk-reflogs with --graph");
> +		die(_("options '%s' and '%s' cannot be used together"), "--walk-reflogs", "--graph");
>  	if (revs->no_walk && revs->graph)
> -		die("cannot combine --no-walk with --graph");
> +		die(_("options '%s' and '%s' cannot be used together"), "--no-walk", "--graph");
>  	if (!revs->reflog_info && revs->grep_filter.use_reflog_filter)
> -		die("cannot use --grep-reflog without --walk-reflogs");
> +		die(_("%s requires %s"), "--grep-reflog", "--walk-reflogs");

This last transformation does not fit the topic of this patch. It should go into patch 6/11, I think.

>  
>  	if (revs->line_level_traverse &&
>  	    (revs->diffopt.output_format & ~(DIFF_FORMAT_PATCH | DIFF_FORMAT_NO_OUTPUT)))
-- Hannes
Previous: Jean-Noël Avila via GitGitGadgetNext: Jean-Noël AVILA
Message 50 of 94 in “Factorization of messages with similar meaning”
  1. 00/10 Factorization of messages with similar meaningJean-Noël Avila via GitGitGadget, Dec 3, 2021
  2. 02/10 i18n: refactor "%s, %s and %s are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  3. 04/10 i18n: standardize "cannot open" and "cannot read"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  4. Ævar Arnfjörð BjarmasonDec 7, 2021
  5. 01/10 i18n: refactor "foo and bar are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  6. Ævar Arnfjörð BjarmasonDec 7, 2021
  7. Jean-Noël AVILADec 8, 2021
  8. 05/10 i18n: tag.c factorize i18n stringsJean-Noël Avila via GitGitGadget, Dec 3, 2021
  9. Ævar Arnfjörð BjarmasonDec 7, 2021
  10. 03/10 i18n: turn "options are incompatible" into "are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  11. 06/10 i18n: factorize "--foo requires --bar" and the likeJean-Noël Avila via GitGitGadget, Dec 3, 2021
  12. 08/10 i18n: refactor "unrecognized %(foo) argument" stringsJean-Noël Avila via GitGitGadget, Dec 3, 2021
  13. Ævar Arnfjörð BjarmasonDec 7, 2021
  14. 07/10 i18n: factorize "no directory given for --foo"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  15. 09/10 i18n: factorize "--foo outside a repository"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  16. 10/10 i18n: ref-filter: factorize "%(foo) atom used without %(bar) atom"Jean-Noël Avila via GitGitGadget, Dec 3, 2021
  17. Jeff KingDec 3, 2021
  18. Johannes SixtDec 3, 2021
  19. Junio C HamanoDec 5, 2021
  20. Jean-Noël AVILADec 5, 2021
  21. Johannes SixtDec 5, 2021
  22. Junio C HamanoDec 6, 2021
  23. Junio C HamanoDec 5, 2021
  24. 00/11 Factorization of messages with similar meaningJean-Noël Avila via GitGitGadget, Dec 27, 2021
  25. 01/11 i18n: refactor "foo and bar are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  26. 02/11 i18n: refactor "%s, %s and %s are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  27. 05/11 i18n: tag.c factorize i18n stringsJean-Noël Avila via GitGitGadget, Dec 27, 2021
  28. Junio C HamanoDec 27, 2021
  29. Ævar Arnfjörð BjarmasonDec 27, 2021
  30. Junio C HamanoDec 28, 2021
  31. Jean-Noël AVILADec 29, 2021
  32. 06/11 i18n: factorize "--foo requires --bar" and the likeJean-Noël Avila via GitGitGadget, Dec 27, 2021
  33. Johannes SixtDec 28, 2021
  34. Jean-Noël AVILADec 29, 2021
  35. 07/11 i18n: factorize "no directory given for --foo"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  36. 04/11 i18n: standardize "cannot open" and "cannot read"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  37. 03/11 i18n: turn "options are incompatible" into "cannot be used together"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  38. 10/11 i18n: ref-filter: factorize "%(foo) atom used without %(bar) atom"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  39. 09/11 i18n: factorize "--foo outside a repository"Jean-Noël Avila via GitGitGadget, Dec 27, 2021
  40. 08/11 i18n: refactor "unrecognized %(foo) argument" stringsJean-Noël Avila via GitGitGadget, Dec 27, 2021
  41. 11/11 i18n: turn even more messages into "cannot be used together" onesJean-Noël Avila via GitGitGadget, Dec 27, 2021
  42. Johannes SixtDec 28, 2021
  43. Jean-Noël AVILADec 29, 2021
  44. 00/11 Factorization of messages with similar meaningJean-Noël Avila via GitGitGadget, Dec 29, 2021
  45. 01/11 i18n: refactor "foo and bar are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  46. 02/11 i18n: refactor "%s, %s and %s are mutually exclusive"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  47. Junio C HamanoDec 30, 2021
  48. Jean-Noël AVILADec 31, 2021
  49. 03/11 i18n: turn "options are incompatible" into "cannot be used together"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  50. Johannes SixtDec 29, 2021
  51. Jean-Noël AVILADec 30, 2021
  52. Junio C HamanoDec 30, 2021
  53. 04/11 i18n: standardize "cannot open" and "cannot read"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  54. 05/11 i18n: tag.c factorize i18n stringsJean-Noël Avila via GitGitGadget, Dec 29, 2021
  55. René ScharfeJan 1, 2022
  56. 08/11 i18n: refactor "unrecognized %(foo) argument" stringsJean-Noël Avila via GitGitGadget, Dec 29, 2021
  57. 07/11 i18n: factorize "no directory given for --foo"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  58. Junio C HamanoDec 30, 2021
  59. 11/11 i18n: turn even more messages into "cannot be used together" onesJean-Noël Avila via GitGitGadget, Dec 29, 2021
  60. Junio C HamanoDec 30, 2021
  61. Jean-Noël AVILADec 31, 2021
  62. Junio C HamanoJan 3, 2022
  63. 10/11 i18n: ref-filter: factorize "%(foo) atom used without %(bar) atom"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  64. 09/11 i18n: factorize "--foo outside a repository"Jean-Noël Avila via GitGitGadget, Dec 29, 2021
  65. 06/11 i18n: factorize "--foo requires --bar" and the likeJean-Noël Avila via GitGitGadget, Dec 29, 2021
  66. 00/11 Factorization of messages with similar meaningJean-Noël Avila via GitGitGadget, Jan 2, 2022
  67. 01/11 i18n: refactor "foo and bar are mutually exclusive"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  68. 02/11 i18n: refactor "%s, %s and %s are mutually exclusive"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  69. Johannes SixtJan 3, 2022
  70. 03/11 i18n: turn "options are incompatible" into "cannot be used together"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  71. 04/11 i18n: standardize "cannot open" and "cannot read"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  72. 05/11 i18n: tag.c factorize i18n stringsJean-Noël Avila via GitGitGadget, Jan 2, 2022
  73. René ScharfeJan 2, 2022
  74. Jean-Noël AVILAJan 2, 2022
  75. 08/11 i18n: refactor "unrecognized %(foo) argument" stringsJean-Noël Avila via GitGitGadget, Jan 2, 2022
  76. 07/11 i18n: factorize "no directory given for --foo"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  77. 06/11 i18n: factorize "--foo requires --bar" and the likeJean-Noël Avila via GitGitGadget, Jan 2, 2022
  78. 09/11 i18n: factorize "--foo outside a repository"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  79. 10/11 i18n: ref-filter: factorize "%(foo) atom used without %(bar) atom"Jean-Noël Avila via GitGitGadget, Jan 2, 2022
  80. 11/11 i18n: turn even more messages into "cannot be used together" onesJean-Noël Avila via GitGitGadget, Jan 2, 2022
  81. 00/11 Factorization of messages with similar meaningJean-Noël Avila via GitGitGadget, Jan 5, 2022
  82. 01/11 i18n: refactor "foo and bar are mutually exclusive"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  83. 02/11 i18n: refactor "%s, %s and %s are mutually exclusive"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  84. 04/11 i18n: standardize "cannot open" and "cannot read"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  85. 03/11 i18n: turn "options are incompatible" into "cannot be used together"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  86. 05/11 i18n: tag.c factorize i18n stringsJean-Noël Avila via GitGitGadget, Jan 5, 2022
  87. 07/11 i18n: factorize "no directory given for --foo"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  88. 06/11 i18n: factorize "--foo requires --bar" and the likeJean-Noël Avila via GitGitGadget, Jan 5, 2022
  89. 08/11 i18n: refactor "unrecognized %(foo) argument" stringsJean-Noël Avila via GitGitGadget, Jan 5, 2022
  90. 11/11 i18n: turn even more messages into "cannot be used together" onesJean-Noël Avila via GitGitGadget, Jan 5, 2022
  91. 09/11 i18n: factorize "--foo outside a repository"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  92. 10/11 i18n: ref-filter: factorize "%(foo) atom used without %(bar) atom"Jean-Noël Avila via GitGitGadget, Jan 5, 2022
  93. Johannes SixtJan 5, 2022
  94. Junio C HamanoJan 5, 2022

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.