Bug 240689 - prepare-commit-msg adds comments when called with --no-edit
Summary: prepare-commit-msg adds comments when called with --no-edit
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sam Sneddon [:gsnedders]
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-05-19 15:30 PDT by Sam Sneddon [:gsnedders]
Modified: 2022-05-19 19:34 PDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
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>