trilbymedia / grav-plugin-git-sync

Collaboratively Synchronize your Grav `user` folder hosted on GitHub, BitBucket or GitLab
Apache License 2.0
245 stars 57 forks source link

Added options to disable automatic sync on save/delete/media. #105

Closed AmauryCarrade closed 6 years ago

AmauryCarrade commented 6 years ago

If the corresponding options are disabled, sync will not occur when the user saves pages, delete them, or upload/remove media.

These parameters could be used to fix performances issues due to the git pull/push being synchronously executed when pages are saved, implying way too long loading times. But sync must be done manually or using a cron if auto sync is disabled (obviously).

I also added a warning about that in the configuration page, just above the new sync options.

The new sync options are enabled by default, so if an existing installation is updated, the behaviour will not change at all.

If you want, I can tailor the options (if you want more or less granularity), and update the changelog.

Fixes #51.