Feature Request: enhance Git-GUI's Checkout Branch screen

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Git gurus, throw this one on your to-do list:

This is a feature request to enhance the Git GUI to make it easier to
checkout non-existing branches that exist upstream. Apologies if this
is not the correct place for feature requests.

Scenario: Upstream repo has 4 branches - master, develop, maint, test.
Local repo has only a master branch. In the command line, to switch to
a local copy of the test branch, it is a simple "git checkout test".
The git command automatically realizes your requested branch doesn't
exist but origin does have a branch named test, so it a) creates a
local branch off of origin/develop, b) sets the appropriate pull link,
and c) sets the appropriate push link. In effect, the git command line
hides the fact that the user doesn't know the branch doesn't exist and
creates it as the user was expecting it to exist as. The Git GUI has
no shortcut like this.

For reference, from the man page for git-checkout:
"If <branch> is not found but there does exist a tracking branch in
exactly one remote (call it <remote>) with a matching name, treat as
equivalent to "git checkout -b <branch> --track <remote>/<branch>".

Currently, in order to checkout a non-existing branch in the GUI you
must go to the Branch Menu, click Create, select the "Tracking Branch"
radio, select the branch, then go back up and name the branch the
exact same name (to ease new user confusion). For a new user who just
wants a copy of the remote branch, it is very unintuitive to create a
new branch.

Fortunately, you already have some explicit warning messages after the
Checkout Branch screen if the user intuitively tries to checkout the
tracking branch, but even then a new user rarely realizes what they
have gotten themselves into. At best, they know that they must find
help (just for trying to checkout a branch).

In order to implement this feature effectively, I suggest that the
Checkout Branch screen be modified in one of two ways (exclusive):

Option A:
Merge the Local and Tracking Branch lists into one box keeping their
entries separate by their full name ("master" and "origin/master"). If
a user selects a remote branch, ask the user whether to create the
local branch or move to the detached HEAD state (current
functionality).

Option B (preferred):
Keep the Local and Tracking Branch lists separate (as they are now),
and keep the Tracking Branch list as-is. However, on the Local Branch
screen, select include the existing branches in normal font but also
include potential local branches based off of the remote in italics
(or greyed-out, or asterisked, etc). Selecting an italicized entry
creates the new branch from the tracking branch, without user
interaction.


Thanks,

John Medema
Systems Administrator
United Drugs, a Subsidiary of AAP (American Associated Pharmacies)
john.medema@xxxxxxxxxxxxxxx
7243 N 16th Street, Phoenix, AZ 85020
Office:  602-678-1179 x126
Fax:  602-639-4631

-- 
HIPAA NOTICE:  It is against United Drugs’ policy to receive or send 
un-encrypted or non-secured email correspondence containing Protected 
Health Information (PHI) as defined by HIPAA law.
 
Please use fax or phone for correspondence containing PHI.

-- 
This email message is for the sole use of the intended recipient(s) and may 
contain confidential and privileged information. Any unauthorized review, 
use, disclosure or distribution is prohibited. If you are not the intended 
recipient, contact the sender by reply email, and destroy all copies of the 
original message. 
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]