]> git.ipfire.org Git - thirdparty/git.git/commit - sequencer.c
commit: move post-rewrite code to libgit
authorPhillip Wood <phillip.wood@dunelm.org.uk>
Fri, 17 Nov 2017 11:34:48 +0000 (11:34 +0000)
committerJunio C Hamano <gitster@pobox.com>
Sat, 18 Nov 2017 03:38:10 +0000 (12:38 +0900)
commita87a6f3c98ea80740fa31d2559b78f75f8138132
tree7eb2ddf2897d262bb299c72dff5bc7b85cafd2ba
parent0505d604c9c5a361ee027d155c7d1facaf326863
commit: move post-rewrite code to libgit

Move run_rewrite_hook() from bulitin/commit.c to sequencer.c so it can
be shared with other commands and add a new function
commit_post_rewrite() based on the code in builtin/commit.c that
encapsulates rewriting notes and running the post-rewrite hook. Once
the sequencer learns how to create commits without forking 'git
commit' these functions will be used when squashing commits.

Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/commit.c
sequencer.c
sequencer.h