"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Stefan Sperling <stsp@stsp.name>
Subject:
Re: got histedit -d (drop all commits)
To:
Mark Jamsek <mark@jamsek.com>
Cc:
Game of Trees <gameoftrees@openbsd.org>
Date:
Mon, 30 Jan 2023 15:19:09 +0100

Download raw body.

Thread
On Tue, Jan 31, 2023 at 12:16:26AM +1100, Mark Jamsek wrote:
> As discussed on irc, the below diff introduces the histedit -d flag,
> which is like -f but drops all commits. Regress has also been added for
> the new flag.
> 
> While writing this, I noticed we missed a conflict check for -f and -e,
> which is included in the diff, but I should probably send as a separate
> commit.
> 
> diffstat /home/mark/src/got
>  M  got/got.1                    |    9+   1-
>  M  got/got.c                    |   41+  11-
>  M  regress/cmdline/histedit.sh  |  117+   0-
> 
> 3 files changed, 167 insertions(+), 12 deletions(-)

Nice, ok by me.

One can already use 'got ref' or 'got branch' to achieve a similar effect.
But it is a good idea to make this functionality easy to discover and use
with the histedit command.