I have create my git server with this link link git clone working in server but when i clone my project on local machine i have a problem "warning: remote HEAD refers to nonexistent ref, unable to checkout." i used for clone "git clone http://domain.com/project.git " i used virtual machine(domain.com =192.168.1.196) for git server and windows for local machine. Thanks
On the server run the following command in a new folder to initialize a new bare git repo...
git init --bare
On your local machine go to an existing folder of create a new one and run.
git init
Copy a file into this folder and execute.
git commit -am "New repository with a new file"
Then add your server as a remote.
git remote add myserver http://domain.com/project.git
Next step is to push to your server.
git push -u myserver master
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.