I am using Amazon Ec2 . I am trying to create a Remote Repo on the Ec2 server to which I can check in code and run my server from there .
Ec2 Server
Here is created two folders
/home/ubuntu/project.git <---- Repo
/home/ubuntu/project <---- Source files to run server
I followed the instructions given here - http://blog.soarez.com/post/56644329478/deploy-a-node-js-service-on-ec2-with-git
Now from my local computer , I pushed the source files to project.git . It works fine . Files get pushed into the repo.
Now how do I get the files from the project.git to the project folder . I tried doing this , but it doesnt work -
cd ~/project.git
GIT_WORK_TREE=/home/ubuntu/project git checkout -f