Anyone know how to link a local Github repo with the Wamp server? I'm trying to run my project with localhost so I'm using Wamp. Whenever I run these commands
cd C:\Users\my\Documents\GitHub\repo
git --work-tree=C:\wamp\www status
(repo
is the name of the repo)
to link them up though (as suggested by another user in this thread Can I combine my local Github repository with WAMP localhost folder?), I get a "fatal: This operation must be run in a work tree.
"
The user's other answers don't work either.
There have been similar questions on Stack Overflow and I've tried all the suggested solutions, and none have worked. Some suggested that my repository was bare, but I'm able to do git add, commit, push, pull, so I'm not sure why I'm getting that error. I even tried configuring core.bare
to false
, but still get the same error.
Maybe I don't have enough knowledge in using Github to know why I'm getting this error, but I'd appreciate any help.