Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [egit-dev] Let's debate about "Commit and Push" behaviour

On Wed, Aug 6, 2014 at 4:15 PM, Mickael Istria <mistria@xxxxxxxxxx> wrote:
Hi all,

I'd like to debate with you about something I don't like in "Commit and Push" action.
Specifically, it's on line 132 of org.eclipse.egit.ui.internal.commit.CommitJob, in the pushUpstream method [1].

When a push config is already available (push config seem to be created automatically, and as a user, I don't remember I specifically created one; and I don't know much how they are created), it gets systematically used in order to push the new commit. However, it happens *very* often that I want to push to a custom branch, whatever is my current active branch. (As I'm using Gerrit and usually pushing singe commits for review, I don't create topic branch, I switch directly between commits, so I don't really care about branches and don't manage them cleanly). So I almost always want to see the Push wizard to specify how I want to push stuff.
However, in most cases, I don't see this wizard and EGit decides of how to push stuff, which is almost never what I want to do.

Instead, I suggest we always show the (simple [2]) push wizard, and use the push config as initial settings to pre-populate the wizard fields (it seems to me it's already the current behaviour of the wizard). So people who are ok with default settings can just push "Finish" and other ones can perform their tweaks.
This approach would have the benefit of being usable for everyone, the drawback is that people who are happy with the stored configuration have 1 more click to do.

More generally, I would rather always see the Simple Push wizard before direct push action.

Do you think my use-case is worth adding a click to some other people? I'm not sure whether one scenario is much more common than the other.

I think we should not add another click for everybody using the commit+push button.

We could add a hint where changes will be pushed similar to the recent
enhancements you did for "Push branch". Maybe we could add this as
an editable field so that you can both see the target of the push and change
it if necessary but without adding another click in case the configured 
target is ok.




If you are using Gerrit you probably most often push to refs/for/master ?
If you set the push refspec to HEAD:refs/for/master you can push changes from
any local branch to Gerrit's review queue for the master branch.

--
Matthias

Back to the top