Rebase with tags

3 messages, 3 authors, 2016-06-15 · open the first message on its own page

Rebase with tags

From: Leonid Podolny <hidden>
Date: 2016-06-15 22:49:39

Hi,
I would expect this question to be asked dozens of times already, but
surprisingly I can't readily find an answer.
Is it possible to transfer tags to a new branch during rebase? I mean,
during the rebase process, when git applies a tagged commit, I want it
to transfer a tag to a new commit.
Is it possible, at least, to receive a set of (old commit, new commit)
pairs, so that I will write a little script that will do that for me?

Re: Rebase with tags

From: Jon Seymour <hidden>
Date: 2016-06-15 22:49:39


Sent from my iPhone

On 29/09/2010, at 18:45, Leonid Podolny [off-list ref] wrote:
Hi,
I would expect this question to be asked dozens of times already, but
surprisingly I can't readily find an answer.
The reason this is not directly supported is that it encourages people to regard tags as mutable entities that can be changed at will. This goes against the general principle that a tag, once cut, never changes.

Technically you can change a tag, but this is meant to be a measure of last resort not something you do as a matter of course.

That said, I understand the requirement - if you are using tags as markers for different segments of a private history, I can see it would be useful to move the markers when you rebase. 

Perhaps there might be a case for a kind of marker reference that does move with a rebase, but it would be somewhat invasive to implement so you'd have to convince the list it was worthwhile.

jon.

Re: Rebase with tags

From: Thomas Rast <hidden>
Date: 2016-06-15 22:49:39

Leonid Podolny wrote:
Is it possible, at least, to receive a set of (old commit, new commit)
pairs, so that I will write a little script that will do that for me?
The post-rewrite hook gets this list, so you can use that if you want
to.

-- 
Thomas Rast
trast@{inf,student}.ethz.ch
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help