build a git repo and clone
First machine:
git init --bare gitrepo.git
Second machine:
git clone user@server:~/gitrepo.git
cd gitrepo
touch test
git add test
git commit -a
# '-u' tells git to track the remote master branch with your local master branch
git push -u origin master
浙公网安备 33010602011771号