]> git.ipfire.org Git - thirdparty/git.git/commit
contrib: remove "git-resurrect.sh"
authorPatrick Steinhardt <ps@pks.im>
Mon, 12 May 2025 09:19:58 +0000 (11:19 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 12 May 2025 17:55:46 +0000 (10:55 -0700)
commitbb9a9297d708827151442cba4d9f39eeede245a4
treea9fffe8f120a86ca41c61ab4270bf589e63b546c
parent1248fb08d7e87911487fefb9f514d39eb5f4ddcb
contrib: remove "git-resurrect.sh"

The "git-resurrect.sh" script can be used to find traces of a branch tip
in the reflog and resurrect that branch. Despite a couple of global
cleanups, the script hasn't seen any activity since it was introduced in
e1ff064e1bf (contrib git-resurrect: find traces of a branch name and
resurrect it, 2009-02-04).

Furthermore, the tool does not work with the "reftable" backend at all
as it directly reads ".git/logs/HEAD". As reflogs are stored as part of
the individual tables though that file wouldn't exist in a "reftable"-
enabled repository.

Last but not least, the tool doesn't even work unless it is explicitly
invoked via `git resurrect` as it sources "git-sh-setup". As none of our
build systems know to install this script, users thus have to go out of
their way to really make it work, which is highly unlikely.

Another source that indicates that this tool can be removed is a
question for how to restore deleted branches on StackOverflow [1]. The
top-voted answer uses git-reflog(1) directly and has received more than
3000 votes to date. While "git-resurrect.sh" is also mentioned, it only
got 16 upvotes, and comments mention the above caveat that users have to
do some manual setup to make it work.

It's thus rather clear that the tool doesn't have a lot or even any
users. Remove it.

[1]: https://stackoverflow.com/questions/3640764/can-i-recover-a-branch-after-its-deletion-in-git

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/git-resurrect.sh [deleted file]