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

[PATCH] simplify the "no changes added to commit" message

From
Nicolas Pitre <nico@cam.org>
Date
Jan 14, 2007, 02:23 UTC
Message-ID
<Pine.LNX.4.64.0701132111080.2577@xanadu.home>

Suggesting the use of [-a|-i|-o] with git-commit is unnecessarily complex and confusing. In this context -o is totally useless and -i requires extra arguments which are not mentioned. The only sensible hint (besides reading the man page but let's not go there) is "commit -a".

Signed-off-by: Nicolas Pitre <nico@cam.org> ---
diff --git a/wt-status.c b/wt-status.c
index daba9a6..b7250e4 100644
--- a/wt-status.c
+++ b/wt-status.c
@@ -335,7 +335,7 @@ void wt_status_print(struct wt_status *s)
 		if (s->amend)
 			printf("# No changes\n");
 		else if (s->workdir_dirty)
-			printf("no changes added to commit (use \"git add\" and/or \"git commit [-a|-i|-o]\")\n");
+			printf("no changes added to commit (use \"git add\" and/or \"git commit -a\")\n");
 		else if (s->workdir_untracked)
 			printf("nothing added to commit but untracked files present (use \"git add\" to track)\n");
 		else if (s->is_initial)
Next: Juergen Ruehle
Message 1 of 2 in “simplify the "no changes added to commit" message”
  1. simplify the "no changes added to commit" messageNicolas Pitre, Jan 14, 2007
  2. Juergen RuehleJan 14, 2007

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.