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

Re: Feature request: show branches in interactive commit

From
Johannes Sixt <j.sixt@viscovery.net>
Date
Jun 28, 2012, 08:53 UTC
Message-ID
<4FEC1BA5.8030307@viscovery.net>
In-Reply-To
<fd93774cb5ed6d4dee090eb2b0be952e.squirrel@webmail.hitco.org>
Am 6/28/2012 9:54, schrieb Philipp Marek:
Show 15 quoted lines
> Say that "123458" is a commit with "branch1" associated; then I'd hope for output like
> 
>     pick 123456 ...
>     pick 123457 ...
>     pick 123458 ...
>     #x git branch "branch1" --force # move the branch?
>     pick 123459 ...
>     pick 12345a ...
> 
> I have a few feature branches that are stacked upon each other; when moving a commit
> "down" to the release-branch I'd like to have the other branches at the matching "new"
> commit.
> 
> Of course I can simply fix up the "rebase" output in my editor - but I guess that might
> help a few people, that's why I'm proposing it here.

I happen to have one such topic branch stack myself that I carry around since a while. But the implementation must be a bit smarter: What should happen if you --abort after e.g. 123459 was picked?

I used this scheme sometimes:
     pick 123456 ...
     pick 123457 ...
     pick 123458 ...
     x git rev-parse HEAD >sha1
     pick 123459 ...
     pick 12345a ...
     x git branch --force "branch1" $(cat sha1)

Granted, an indication where the topic branch heads would have to go in the todo list, as you suggest, would be nice first step.

-- Hannes
Previous: Philipp Marek
Message 2 of 2 in “Feature request: show branches in interactive commit”
  1. Philipp MarekJun 28, 2012
  2. Johannes SixtJun 28, 2012

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.