Re: Correct way of making existing remote repository "bare"

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

 



Hi,

On Wed, 15 Jul 2009, Graeme Geldenhuys wrote:

> Steps I done:
> 
> * ssh to remote server
> * git clone --bare -l <path_to_repos> <new_dir>
> * renamed old repository directory
> * renamed new repository dir to what old repository used to be.
> 
> Like I said, this did the tick, but is this the correct way of doing it?

That's the easiest.  However, I regularly avoid those steps by doing

	mv bla/.git bla.git
	git --git-dir=bla.git config core.bare true
	rm -rf bla

This requires a bit more familiarity with the Git internals than your 
solution, though (although it makes sure that the config is unchanged, as 
well as possibly installed hooks).

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]