Re: Pushing a git repository to a new server

2013-02-13 Thread Michael J Gruber
Jeff King venit, vidit, dixit 12.02.2013 21:42: > On Tue, Feb 12, 2013 at 12:28:53PM +0100, Michael J Gruber wrote: > >> I'm not sure providers like GitHub would fancy an interface which allows >> the programmatic creation of repos (giving a new meaning to "fork >> bomb"). But I bet you know bette

Re: Pushing a git repository to a new server

2013-02-12 Thread Jeff King
On Tue, Feb 12, 2013 at 12:28:53PM +0100, Michael J Gruber wrote: > I'm not sure providers like GitHub would fancy an interface which allows > the programmatic creation of repos (giving a new meaning to "fork > bomb"). But I bet you know better ;-) You can already do that: http://developer.git

Re: Pushing a git repository to a new server

2013-02-12 Thread Michael J Gruber
Jeff King venit, vidit, dixit 11.02.2013 17:27: > On Mon, Feb 11, 2013 at 02:57:51AM -0500, Ethan Reesor wrote: > >> On Mon, Feb 11, 2013 at 2:50 AM, Konstantin Khomoutov >> wrote: >>> What's wrong with >>> $ ssh myuser@remotehost 'mkdir /path/to/MyRepo.git; cd $_; git init --bare' >>> $ git push

Re: Pushing a git repository to a new server

2013-02-11 Thread Ethan Reesor
On Mon, Feb 11, 2013 at 7:45 AM, Konstantin Khomoutov wrote: [...] > OK, here's the sketch. > On the server, in the home directory of your "git" user, you create a > wrapper around git-receive-pack, like this: > > # mkdir ~git/git-shell-commands > # cat >~git/git-shell-commands/git-receive-new-rep

Re: Pushing a git repository to a new server

2013-02-11 Thread Ethan Reesor
On Mon, Feb 11, 2013 at 11:27 AM, Jeff King wrote: [...] > We talked about this a long time ago. One problem is that it's > inherently unportable, as the procedure to make a repo is potentially > different on every server (and certainly that is the case between a > regular user running stock git a

Re: Pushing a git repository to a new server

2013-02-11 Thread Jeff King
On Mon, Feb 11, 2013 at 02:57:51AM -0500, Ethan Reesor wrote: > On Mon, Feb 11, 2013 at 2:50 AM, Konstantin Khomoutov > wrote: > > What's wrong with > > $ ssh myuser@remotehost 'mkdir /path/to/MyRepo.git; cd $_; git init --bare' > > $ git push --all git@remotehost:MyOtherRepo.git > > ? > > Nothi

Re: Pushing a git repository to a new server

2013-02-11 Thread Konstantin Khomoutov
On Mon, 11 Feb 2013 02:57:51 -0500 Ethan Reesor wrote: [...] > I want to create a git-command that 1) creates a bare version of the > current repo, 2) and uploads it to the specified path on my server > (using tar, but that's not the point). Thanks, it's now a bit more clear. > My problem is th

Re: Pushing a git repository to a new server

2013-02-10 Thread Ethan Reesor
On Mon, Feb 11, 2013 at 2:50 AM, Konstantin Khomoutov wrote: > What's wrong with > $ ssh myuser@remotehost 'mkdir /path/to/MyRepo.git; cd $_; git init --bare' > $ git push --all git@remotehost:MyOtherRepo.git > ? Nothing, I just wanted to make myself a command to do that for me. >> The reason I

Re: Pushing a git repository to a new server

2013-02-10 Thread Konstantin Khomoutov
On Sun, Feb 10, 2013 at 04:00:56PM -0500, Ethan Reesor wrote: > I'm looking to make a command to push a git repo to a new server. The > way I just did it is as follows: > > localhost> git clone --bare /path/to/MyRepo /path/to/tmpdir/MyRepo.git > localhost> tar xz /path/to/tmpdir/MyRepo.git | ssh