You need to be in your local repo (the one you want to be deployed) in order to make that command.
cd /path/tpo/your/local/repo
git remote add xxxyyy user@XXX.XXX.XX.XXX:/var/myRepo.git
Then you will be able to push (and populate) the bare repo on the server with:
git push -u myServer master
(sill executed from your local repo folder)
Note the -u
: I like to establish a remote tracking branch relationship between your local master
and your server repo master
, especially when the remote repo is empty.
See "Why do I need to explicitly push a new branch?"
After that, a simple git push will be enough.