How do I initialise a folder over ssh in git? -


i want push local repository onto web server which not have git using ssh. possible, or need git repository such github this?

i tried:

git init --bare ssh://user@host.com/public_html/test 

error message:

fatal: cannot mkdir ssh://user......../test/: invalid argument 

this error came before had enter password. folder exists.

but didn't work. can't find information in git book.

you need have git on server, once have installed, you'll access server , run (on server):

git init --bare ~/repository.git 

then in local git repository, you'll add remote

git remote add origin user@host.com:~/repository.git 

if not have local git repository created, need clone , can start use , make push / pulls origin

git clone user@host.com:~/repository.git 

and push master branch (or want) it:

git push origin master 

i hope you.


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -