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

Re: git commit -v does not removes the patch

From
Junio C Hamano <gitster@pobox.com>
Date
Nov 22, 2008, 22:43 UTC
Message-ID
<7v4p1zpejx.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<20081122155541.GC6885@neumann>
SZEDER Gábor <szeder@ira.uka.de> writes:
> So, I wonder whether those '--no-verify' options are still required in
> 'git rebase -i'.

The use of --no-verify there does not have anything to do with "whitespace errors". It is to override _any_ validation the users want to do when using "git commit" in their interactive workflow. It so happens that the example hook we ship demonstrates how you hunt for whitespace errors, but you have to remember that it is just an example.

We may want to disable the checking of exit status from commit-msg hook while still calling the hook itself, though. The primary purpose of the hook is to allow users to reformat (say, passing "fmt -64") the message, but it is allowed to interfere and that was meant to happen when using "git commit" but we probably do not want it when rebasing.

Further, we also may want to make the use of --no-verify overridable from the command line when running rebase. The primary purpose of the rebase command is to transplant a sequence of commits to someplace else without molesting its contents and message unnecessarily, and --no-verify is a good thing to use in general for that reason, but people may sometimes want to use it as a way to clean up the changes.

Previous: Jeff King
Message 22 of 22 in “git commit -v does not removes the patch”
  1. Santi BéjarNov 10, 2008
  2. Jeff KingNov 10, 2008
  3. Santi BéjarNov 10, 2008
  4. Junio C HamanoNov 10, 2008
  5. Jeff KingNov 11, 2008
  6. Santi BéjarNov 11, 2008
  7. Jeff KingNov 11, 2008
  8. Santi BéjarNov 11, 2008
  9. Junio C HamanoNov 11, 2008
  10. Jeff KingNov 12, 2008
  11. 1/5 define empty tree sha1 as a macroJeff King, Nov 12, 2008
  12. 2/5 wt-status: refactor initial commit printingJeff King, Nov 12, 2008
  13. 3/5 status: show "-v" diff even for initial commitJeff King, Nov 12, 2008
  14. 4/5 commit: loosen pattern for matching "-v" diffJeff King, Nov 12, 2008
  15. 5/5 commit: only strip diff from message in verbose modeJeff King, Nov 12, 2008
  16. Jeff KingNov 12, 2008
  17. Junio C HamanoNov 13, 2008
  18. SZEDER GáborNov 20, 2008
  19. Jeff KingNov 20, 2008
  20. SZEDER GáborNov 22, 2008
  21. Jeff KingNov 22, 2008
  22. Junio C HamanoNov 22, 2008

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.