I have a Git repo one one server. i want that whenever an admin pushes changes to git repo, those changes may automatically be deployed to a folder on the same server, where git repo is hosted.
As my repo is in /opt/myrepo.git , i have created the scripts /opt/myrepo.git/hooks/post-commit .
when i perform any commit on the repo, the above script should run, but it does not. i have wrote simple Echo commands in it to test its output to a file, but it doesnt run at all.