S
S
Salavat Sitdikov2012-06-01 12:26:25
git
Salavat Sitdikov, 2012-06-01 12:26:25

How to set up git to work with an existing project?

So. There is a project on a remote machine
/home/sitename.ru/www

I did the following operations:

$ ssh somehost
$ cd /home/sitename.ru/www
$ git init
$ git add.
$ git commit -m "Initial commit"

$ cd...
$ git clone --bare www www.git

$ mv www www.OLD && git clone www.git www

Everything seems clear here.

Now on my machine I'm trying to do
$ git clone ssh://ip_address/home/sitename.ru/www
or
$ git clone ssh://ip_address/home/sitename.ru/www.git

By zeros. nothing happens :(

Can you at least tell me what query to write for Google?

(Manual according to which I did it - www.ibm.com/developerworks/ru/library/wa-git/index.html )

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
kuzemchik, 2012-06-01
@kuzemchik

even somehow difficult:
cd /home/sitename.ru/
mkdir www.git
cd www.git
git init --bare
cd ../www
git init
git add *
git commit -a -m "Initial commit"
git remote add origin www.git
git push -f origin
from local:
git clone ssh://ip_address/home/sitename.ru/www.git

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question