How to pull a git repository from remote server? -
i've seen few similar questions asked, didn't me figure out, , couldn't find tutorials (i wasn't sure looking for, honest). also, haven't used git apart pulling/pushing onto github, why (at least believe so) confused! github made me spoiled setting repo up!
what did on server:
sudo apt-get install git
installed (i think) needed proceed.- i created test repository (just few txt , html files) inside
git_test
git init
git add .
git commit
- i used
vim .git/description
change descriptionstarships
.
what did computer
i have git pre-installed
git clone destielstarship@
[remote_server]
/starships
1
which produced error: fatal: unable destielstarship@
[remote_server]
(port 9418) (a non-recoverable error occurred during database look-up. )
- i replaced ip address [remote_server] clarity, hope didn't make more confusing.
update: whoops! fixed awkward typo!
tl;dr
unless you're running git-daemon on remote server, want use ssh rather git uri scheme.
ssh schemes
to use ssh transport, can clone repository using different uri scheme. example, assuming username on remote host "destielstarship," use following command:
git clone ssh://destielstarship@remotehost.example.com/path/to/git_test
you can leave off .git extension repository in cases, , need specify username remote host if differs current login.
Comments
Post a Comment