worktree: combine two translatable messages
These two messages differ only by the config key name, which should not be translated. Extract those keys so the messages can be translated from the same string. Reported-by: Jean-Noël AVILA <jn.avila@free.fr> Signed-off-by: Derrick Stolee <derrickstolee@github.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Derrick Stolee committed
Feb 23, 2022 at 14:29 UTC
92d92345ce5996933f5cfc357dce1e1744487b6a
1 file changed
+4
-2
builtin/worktree.c
+4
-2
@@ -384,11 +384,13 @@ static int add_worktree(const char *path, const char *refname,
384
bare &&
385
git_config_set_multivar_in_file_gently(
386
to_file, "core.bare", NULL, "true", 0))
387
- error(_("failed to unset 'core.bare' in '%s'"), to_file);
387
+ error(_("failed to unset '%s' in '%s'"),
388
+ "core.bare", to_file);
389
if (!git_configset_get_value(&cs, "core.worktree", &core_worktree) &&
390
git_config_set_in_file_gently(to_file,
391
"core.worktree", NULL))
391
- error(_("failed to unset 'core.worktree' in '%s'"), to_file);
392
+ error(_("failed to unset '%s' in '%s'"),
393
+ "core.worktree", to_file);
394
395
git_configset_clear(&cs);
396
}