Skip to content

Commit c6e7965

Browse files
pcloudsgitster
authored andcommitted
archive.c: mark more strings for translation
Two messages also print extra information to be more useful Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent a7412ae commit c6e7965

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

archive.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -385,12 +385,12 @@ static void parse_treeish_arg(const char **argv,
385385
int refnamelen = colon - name;
386386

387387
if (!dwim_ref(name, refnamelen, &oid, &ref))
388-
die("no such ref: %.*s", refnamelen, name);
388+
die(_("no such ref: %.*s"), refnamelen, name);
389389
free(ref);
390390
}
391391

392392
if (get_oid(name, &oid))
393-
die("Not a valid object name");
393+
die(_("not a valid object name: %s"), name);
394394

395395
commit = lookup_commit_reference_gently(ar_args->repo, &oid, 1);
396396
if (commit) {
@@ -403,7 +403,7 @@ static void parse_treeish_arg(const char **argv,
403403

404404
tree = parse_tree_indirect(&oid);
405405
if (tree == NULL)
406-
die("not a tree object");
406+
die(_("not a tree object: %s"), oid_to_hex(&oid));
407407

408408
if (prefix) {
409409
struct object_id tree_oid;
@@ -413,7 +413,7 @@ static void parse_treeish_arg(const char **argv,
413413
err = get_tree_entry(&tree->object.oid, prefix, &tree_oid,
414414
&mode);
415415
if (err || !S_ISDIR(mode))
416-
die("current working directory is untracked");
416+
die(_("current working directory is untracked"));
417417

418418
tree = parse_tree_indirect(&tree_oid);
419419
}

0 commit comments

Comments
 (0)