Keep website in sync with offline/online version?

What is the best approach for managing a website with DVCS?
I have my grav website checked in a git repository. and then uploaded everything to my provider, except the .git repository.

Is this the common approach for managing a website?

The best approach is to deploy to your online site via the Git repo. I outlined the approach we use with a posthook here: http://getgrav.org/blog/developing-with-github-part-1 and http://getgrav.org/blog/developing-with-github-part-2

This is the approach we use for all our sites. We don’t manage them live at all, everything is done local or on stating servers and then pushed to github/bitbucket which then automatically pushes to production.

From the article it is not clear for me, why I need the github wrapper for deploying my site?

You just need something public the production server can pull from. Also the posthook is handy too. You could use another service and manually pull too.

Try putting your code blocks in between ``` triple backticks…