summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
authorKarthik Nayak <karthik.188@gmail.com>2025-03-14 09:40:34 +0100
committerJunio C Hamano <gitster@pobox.com>2025-03-17 16:58:11 -0700
commit52f2dfb08413d8be6ecbe86271dfe92e33cb67a2 (patch)
tree6747c6b64ca26b0d10f990af7b6d71e00cfcf448 /builtin
parenta36e024e989f4d35f35987a60e3af8022cac3420 (diff)
reflog: improve error for when reflog is not found
The 'git reflog expire' prints the error message '<ref> points nowhere!' when used with a non-existent ref. This message is a bit confusing and vague. Modify the message to be more clear and direct. Signed-off-by: Karthik Nayak <karthik.188@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
-rw-r--r--builtin/reflog.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/reflog.c b/builtin/reflog.c
index 95f264989b..762719315e 100644
--- a/builtin/reflog.c
+++ b/builtin/reflog.c
@@ -383,7 +383,7 @@ static int cmd_reflog_expire(int argc, const char **argv, const char *prefix,
struct expire_reflog_policy_cb cb = { .cmd = cmd };
if (!repo_dwim_log(the_repository, argv[i], strlen(argv[i]), NULL, &ref)) {
- status |= error(_("%s points nowhere!"), argv[i]);
+ status |= error(_("reflog could not be found: '%s'"), argv[i]);
continue;
}
set_reflog_expiry_param(&cb.cmd, ref);