I set up a repo on a shared hosting server. I want to use git from now on for pushing my local changes directly to my shared host, but despite the ok message I still see no changes in files:
ON SHARED HOST (REMOTE SERVER)
Initialize git repo
cd public_html/.git
git init
git add .
git commit -m 'First commit'
ON MY LAPTOP (LOCAL SERVER)
I cloned it the central remote repo on local machine
git clone ssh://me@mdomain.ro:15554/home/mydomain/public_html/.git
Now I have a working copy of the remote repository I only have one branch called 'master'. I can see it:
git branch
I add the remote repository under the name 'origin':
git remote add origin ssh://me@mdomain.ro:15554/home/mydomain/public_html/.git
I can list the remote repositories:
git remote
will display: origin At this stage I have done my work commit my changes again (as above) Now I push the changes back to the remote server where my main repository is.
git push origin master
ON SHARED HOST (REMOTE SERVER)
I managed to make it somehow by converting the remote repository to bare repository:
git config --bool core.bare true
ON MY LAPTOP (LOCAL SERVER)
I push again the data:
git push origin master
and got
Compressing objects: 100% (30/30), done.
Writing objects: 100% (32/32), 663.98 KiB, done.
Total 32 (delta 21), reused 0 (delta 0)
To ssh://me@mdomain.ro:15554/home/mdomain.ropublic_html/.git
a416e72..bb19005 master -> master
However, when accessing my url in browser I still cannot see changes. What is wrong?