Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

set a ftp repository with git

Tags:

git

ftp

I want to change my repository from bazaar to git. I installed Git (winXP) and tortoise with no problem, I set path variables, etc...

I have initialized my repository with:

$ git init

copied it using

$ cd ..
$ git clone --bare project.git

uploaded it to FTP, and when trying to access:

$ git clone  *ftp_address*
Initialized empty Git repository in D:/project/.git/
Password:
error: Access denied: 530 while accessing *ftp_address*/info/refs
fatal: HTTP request failed

I checked and .../project.git/info/refs does not exists. What am I missing?

PD: ftp_address = 'ftp://user%[email protected]/git/project.git'

like image 479
enboig Avatar asked May 28 '10 15:05

enboig


1 Answers

As mentioned in Git everyday, you need to make sure your info/refs and objects/info/packs are up-to-date.
Hence the git --bare update-server-info

Regarding the @ issue, the url is usually ftp://login:pass@serveur.
If you have an @ in the login, that makes for an extra (and incorrect) separator.

%40 should be the right way to include an @ in the login name.

You can try as an ftp address:

*ftp_address* = 'ftp://"user%40example.org"@ftp.example.org/git/project.git'

(or some other kind of quotes or double quotes definition to better isolate the username)

like image 195
VonC Avatar answered Sep 19 '22 02:09

VonC