Bug 240689

Summary: prepare-commit-msg adds comments when called with --no-edit
Product: WebKit Reporter: Sam Sneddon [:gsnedders] <gsnedders>
Component: Tools / TestsAssignee: Sam Sneddon [:gsnedders] <gsnedders>
Status: RESOLVED FIXED    
Severity: Normal CC: webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Description Sam Sneddon [:gsnedders] 2022-05-19 15:30:41 PDT
If I run `git commit --amend --no-edit` with a commit whose message is "foo", I end up with:

foo

# Please populate the above commit message. Lines starting
# with '#' will be ignored

# On branch git-editor-colon
# Changes to be committed:
#   (use "git restore --staged <file>..." to unstage)
# 	modified:   Tools/Scripts/hooks/prepare-commit-msg
# 
# Changes not staged for commit:
#   (use "git add <file>..." to update what will be committed)
#   (use "git restore <file>..." to discard changes in working directory)
# 	modified:   Tools/Scripts/hooks/prepare-commit-msg
# 
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
# 	Source/InternalSettingsGenerated.idl
#
Comment 1 Sam Sneddon [:gsnedders] 2022-05-19 16:47:55 PDT
Pull request: https://github.com/WebKit/WebKit/pull/810
Comment 2 EWS 2022-05-19 19:33:13 PDT
Committed r294524 (250779@main): <https://commits.webkit.org/250779@main>

Reviewed commits have been landed. Closing PR #810 and removing active labels.
Comment 3 Radar WebKit Bug Importer 2022-05-19 19:34:16 PDT
<rdar://problem/93624124>