Re: Cloning empty repositories, was Re: What is the idea for bare repositories?

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

 



Hi,

On Wed, 14 Nov 2007, Bill Lear wrote:

> On Wednesday, November 14, 2007 at 11:32:32 (-0800) Junio C Hamano writes:
>
> >But cloning void to start the same project by multiple people and 
> >pushing their initial commits as roots to start a project indicates the 
> >lack of developer communication (besides, it just feels like a bad 
> >style, a hangover from centralized SCM mentality, but that is fine). 
> >...
> 
> We have several users who have been using git for the past 9 months and 
> they each find this unreasonably complicated.  [...]
> 
> Well, here's what we'd like:
> 
> % mkdir new_repo
> % cd new_repo
> % git --bare init
> 
> [on another machine:]
> % git clone git://host/new_repo
> % cd new_repo
> % git init
> [add content]
> % git commit -a -m "Initial stuff"
> % git push

I have a better idea:

[the initial import, on another machine:]
% mkdir new_repo
% cd new_repo
% git init
[add content]
% git commit -a -m "Initial stuff"
% git remote add origin git://host/repo
% git push origin master

If you do not want to be bothered with setting up the default 
"remote" and "merge" config variables manually, it is reasonable to ask 
for support to do that in "git remote".

If you really think that this workflow has anything to do with cloning an 
empty repository, I cannot help you.  I mean, you did not need to clone 
the big, empty void to do the initial commit, or did you?

(I actually think that it is another example of cvs/svn damage, where you 
_need_ to clone first, or otherwise you will _never_ be able to commit 
to the repository.)

BTW I am somewhat disgusted by your usage of git:// for pushing.

Ciao,
Dscho

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

  Powered by Linux