zbg icon indicating copy to clipboard operation
zbg copied to clipboard

New Command: `zbg amend`

Open apainintheneck opened this issue 2 years ago • 3 comments

I'm wondering if this would be worth adding. I know that I tend to use git commit --amend a lot when working on projects if my commits tend to be related somehow before pushing to some remote branch. This is somewhat destructive because it changes the previous commit but in that case we could just hide it behind a prompt if we're worried about that.

apainintheneck avatar May 20 '23 07:05 apainintheneck

Sounds like a good idea! I do occasionally use --amend as well.

From my experience of using this command, the following works nicely and I'd happily merge a PR that adds the following as zbg amend:

git commit --amend --no-edit --date=now

chshersh avatar May 22 '23 21:05 chshersh

I guess I'd prefer to omit the --no-edit flag though I don't really feel that strongly either way. I use git commit --amend with and without that flag right now but I think I'd prefer to have a more verbose default in this case.

apainintheneck avatar May 25 '23 07:05 apainintheneck

@apainintheneck That sounds like a reasonable default to me, so I'm happy to accept this new command as a PR 🙂

chshersh avatar Jun 10 '23 09:06 chshersh