Re: [RFC] git-clone: add --track <headname> support

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

 



Martin Langhoff <martin@xxxxxxxxxxxxxxx> writes:

> Add support for a simplified workflow where users
> want to clone and start working on a head that is
> different from the HEAD of the repository.
>
> Calling
>
>    git-clone --track maint <repo>
>
> Is equivalent to
>
>    git-clone <repo> mydir
>    cd mydir
>    git-checkout --track -b maint origin/maint
>
> --
>
> Not sure if Junio wants this, but if I am going to migrate
> away from cogito, I'd like these common operations to be
> dead simple. 

I am not interested in moving people away from cogito ;-).

With the talk about making more things built-in, I think the
changes to clone and fetch should be done by first rewriting
git-clone as a very thin shell wrapper that essentially does:

	figure out the directory name to use
        mkdir that directory and cd into it
        run git init with appropriate options
        run git remote add with appropriate options
        run git fetch with appropriate options
        run git checkout with appropriate options (unless -n)

Also you might want to check "branch.autosetupmerge" config.  It
seems to be described in git-branch manual page without being
listed in Documentation/config.txt, which is a bad that happend
some time ago X-<.

It seems that today has been a day to discover many bads that
happened some time ago for me X-<.  I should quit and call it a
day now...


-
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]