Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [egit-dev] Commit + Push no longer using "Push to origin" config

Thanks for the context Thomas. Appreciate it!


> On Mar 22, 2022, at 22:58, Thomas Wolf <thomas.wolf@xxxxxxxxxx> wrote:
> 1. Make push behave like "push to origin" again? Even if that would push
>   more than one branch?
> 2. Do so only if the remote config has exactly one non-wildcard refspec?
> 3. Leave as is now, but figure out a way to push or force push? (Bug
>   411219.[3])
> 4. Add a preference where the user can choose whether to consider the
>   branch config (branch.<name>.merge) in preference over the remote
>   config?
> 5. Something else?

I don't have strong opinion whether *all* branches should be pushed or just the one receiving the commit. Form a UX point of you the latter seems to make a lot of sense.

My use case is specifically Commit Amend + Push, which is now broken without the force flag.

> I have no clear idea how to do (3). An extra checkbox might take
> too much screen estate, but is otherwise the simplest option. (State
> would need to be persisted per repo.) A "SplitButton" (Button with drop-
> down menu) as suggested in bug 411219 doesn't exist in SWT apparently
> because it doesn't exist natively on all platforms; I don't think Cocoa
> has something that. Using Ctrl-Click or Ctrl-Space for "force push" is
> not easily discoverable by the user and I'm off-hand not even sure we'd
> have the keypress state in a mouse click event.

We've created a preference page for tweaking the behavior of that specific button. IMO it should go there.


> One thing I don't quite get: do you change the remote's push refspec
> every time you switch branches to update the destination? That can't be
> a comfortable workflow either... I imagine you have something like
> +HEAD:refs/heads/some_branch. How do you set the destination per
> local feature branch?

I use a * ref spec. All "my/*" branches will be force pushed.

-Gunnar

-- 
Gunnar Wagenknecht
gunnar@xxxxxxxxxxxxxxx, http://guw.io/



Back to the top