delete a topic

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|

delete a topic

Raffaele Salmaso-2
Hi all,
I'm testing the topic extension.
It is possible to delete a topic in a draft phase?

Thanks

--

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

Re: delete a topic

Boris Feld
Yes you can with:

hg topics --rev <related revset> --clear

You may also want to clear the current topic with:

hg topics --clear

Cheers,
Boris

On Wed, 2017-10-04 at 09:17 +0200, Raffaele Salmaso wrote:
Hi all,
I'm testing the topic extension.
It is possible to delete a topic in a draft phase?

Thanks

--
_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

Re: delete a topic

Raffaele Salmaso-2
On Wed, Oct 4, 2017 at 11:14 AM, Boris Feld <[hidden email]> wrote:
Yes you can with:

hg topics --rev <related revset> --clear

You may also want to clear the current topic with:

hg topics --clear

Cheers,
Boris

Ouch, I've done a
hg topic -r REV --clear 
on a secret changeset and it rewrote the changeset in a draft phase (other than it removed the topic only on REV, not all its parents, to do so I have to use
hg topic --clear -r 'topic("ec")'
not really userfriendly - for hg commandline).

I don't think that topics is what I would use: I need bookmarks done right, which I can add/remove/rename without rewriting history.

Am I wrong and is topics exactly this?

Thanks

--

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

topic extension

Mario Castelán Castro
In reply to this post by Boris Feld
What is this topic extension? I can not find any link to the actual
source code neither in the Mercurial Wiki nor doing a search with
DuckDuckGo.

--
Do not eat animals; respect them as you respect people.
https://duckduckgo.com/?q=how+to+(become+OR+eat)+vegan


_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial

signature.asc (235 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Nathan Goldbaum
It's included in the evolve extension. I believe it's still considered somewhat experimental, along with the rest of the evolve extension. The idea is to provide an alternative to bookmarks that act a bit more like named branches. Unlike bookmarks, topics are recorded in the commit metadata (like named branches). However, they are only visible when a commit is in draft phase. If the commit is public (i.e. after the code passes code review and is merged or rebased onto the main line of development for a team), the topic "fades away". It will always be in the commit metadata though, so you can always figure out what topic a commit happens on, just like a mercurial named branch.

I'm not sure there are docs beyond this page:


-Nathan

On Wed, Oct 4, 2017 at 10:25 AM, Mario Castelán Castro <[hidden email]> wrote:
What is this topic extension? I can not find any link to the actual
source code neither in the Mercurial Wiki nor doing a search with
DuckDuckGo.

--
Do not eat animals; respect them as you respect people.
https://duckduckgo.com/?q=how+to+(become+OR+eat)+vegan


_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial



_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Mario Castelán Castro
On 04/10/17 10:39, Nathan Goldbaum wrote:
> I'm not sure there are docs beyond this page:
>
> https://www.mercurial-scm.org/doc/evolution/tutorials/topic-tutorial.html

Thanks you.

What is the point of this extension? Why not simply use named branches
and close them before merging?

--
Do not eat animals; respect them as you respect people.
https://duckduckgo.com/?q=how+to+(become+OR+eat)+vegan


_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial

signature.asc (235 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Raffaele Salmaso-2
On Wed, Oct 4, 2017 at 5:44 PM, Mario Castelán Castro <[hidden email]> wrote:
On 04/10/17 10:39, Nathan Goldbaum wrote:
> I'm not sure there are docs beyond this page:
>
> https://www.mercurial-scm.org/doc/evolution/tutorials/topic-tutorial.html

Thanks you.

What is the point of this extension? Why not simply use named branches
and close them before merging?
Named branches can be heavy, expecially with large repositories.
topics should mimics the git branches, where usually you develop in a feature branch before mergin/rebasing to master, and then you usually delete local branch (less clutter), but I just discover that topics are recorded in the changeset, it works only in draft/secret phase (to "remove" you need to publish them), and more important it retouch a commit if cleared with --clear (thanks that was only a test so no real harm is done). I don't know if I like this approach at all.

--

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Mario Castelán Castro
On 04/10/17 23:58, Raffaele Salmaso wrote:
> Named branches can be heavy, expecially with large repositories.
> topics should mimics the git branches, where usually you develop in a
> feature branch before mergin/rebasing to master, and then you usually
> delete local branch (less clutter), but I just discover that topics are
> recorded in the changeset, it works only in draft/secret phase (to "remove"
> you need to publish them), and more important it retouch a commit if
> cleared with --clear (thanks that was only a test so no real harm is done).
> I don't know if I like this approach at all.

Thanks for your reply.

--
Do not eat animals; respect them as you respect people.
https://duckduckgo.com/?q=how+to+(become+OR+eat)+vegan


_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial

signature.asc (235 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Arne Babenhauserheide-2
In reply to this post by Raffaele Salmaso-2

Raffaele Salmaso <[hidden email]> writes:
> Named branches can be heavy, expecially with large repositories.

What do you mean by heavy? And did you test this?
(I once ran tests with 10k branches without getting into problems)

Best wishes,
Arne
--
Unpolitisch sein
heißt politisch sein
ohne es zu merken

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial

signature.asc (847 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Raffaele Salmaso-2
On Thu, Oct 5, 2017 at 7:33 PM, Arne Babenhauserheide <[hidden email]> wrote:

Raffaele Salmaso <[hidden email]> writes:
> Named branches can be heavy, expecially with large repositories.

What do you mean by heavy? And did you test this?
(I once ran tests with 10k branches without getting into problems)
Maybe now it is not more relevant.

--

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

David Demelier-2
In reply to this post by Arne Babenhauserheide-2
On Thu, 2017-10-05 at 19:33 +0200, Arne Babenhauserheide wrote:
> Raffaele Salmaso <[hidden email]> writes:
> > Named branches can be heavy, expecially with large repositories.
>
> What do you mean by heavy? And did you test this?
> (I once ran tests with 10k branches without getting into problems)
>

As they store the branch information in the changeset for ever. Using
branches locally and never share them is not a problem though.

--
David Demelier
_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial
Reply | Threaded
Open this post in threaded view
|

Re: topic extension

Arne Babenhauserheide-2

David Demelier <[hidden email]> writes:

> On Thu, 2017-10-05 at 19:33 +0200, Arne Babenhauserheide wrote:
>> Raffaele Salmaso <[hidden email]> writes:
>> > Named branches can be heavy, expecially with large repositories.
>>
>> What do you mean by heavy? And did you test this?
>> (I once ran tests with 10k branches without getting into problems)
>>
>
> As they store the branch information in the changeset for ever. Using
> branches locally and never share them is not a problem though.
Keep in mind that this stored information does not take much space (and
it quickly disappears in compression) and that if branches are closed,
they do not clutter the interface. Therefore they are not heavy: a
single commit hash takes up much more space than the branch information.

Best wishes,
Arne
--
Unpolitisch sein
heißt politisch sein
ohne es zu merken

_______________________________________________
Mercurial mailing list
[hidden email]
https://www.mercurial-scm.org/mailman/listinfo/mercurial

signature.asc (847 bytes) Download Attachment