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

RFE: teach gitk to automatically mark .git/rebase-merge/stopped-sha

From
Mikko Rantalainen <mikko.rantalainen@peda.net>
Date
May 4, 2020, 08:26 UTC
Message-ID
<1dbc41e9-b2e5-0b77-26c4-c912c82f9069@peda.net>

While doing long rebases (I'm currently rebasing a feature branch with 166 patches) and rebase stopping in the middle of rebase, locating the old patch in gitk is sometimes hard.

Could gitk automatically mark the original patch that failed to rebase after I press F5?

The failing original commit SHA-1 can be found in file .git/rebase-merge/stopped-sha but as far as I know, git does have logical commit name similar to HEAD, ORIG_HEAD or anything else for this case so there's no easy way to get already running gitk to mark this patch.

Of course, doing the same thing for failed cherry-picks would be nice, too but in that case it's pretty clear where the source patch is.

As a workaround I currently have to do something like
  git tag -f FAILED_HEAD $(cat .git/rebase-merge/stopped-sha)
after seeing rebase failure. Then I can hit F5 in gitk to easily locate
the source commit.

PS. Is there a way to automatically run git tag -f FAILED_HEAD $(cat .git/rebase-merge/stopped-sha) if rebase fails in the middle of branch?

-- 
Mikko
Next: Phillip Wood
Message 1 of 3 in “RFE: teach gitk to automatically mark .git/rebase-merge/stopped-sha”
  1. Mikko RantalainenMay 4, 2020
  2. Phillip WoodMay 5, 2020
  3. Philip OakleyMay 5, 2020

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.