Managing a WooCommerce site with Git
-
This is a general question about how to manage a WooCommerce site when the site is version controlled.
Essentially, we have a parent repo, WordPress is a submodule, our theme is a submodule. WooCommerce is in the parent repo.
WooCommerce periodically updates our single-product.php, most often just bumping the version number. This is constantly causing our production environment to have uncommitted changes.
The only options that I can see are:
- Change file permissions so Woo can’t change the file ( probably a bad idea )
- Add single-product.php to the .gitignore. I don’t like this solution either, because we’ll never get the latest version sync’d with Dev and Staging.
My question is, what is the recommended way to keep a production site clean ( meaning, no uncommitted changes ) considering that WooCommerce may, at any time, update a git managed theme?
In my opinion, this is a bug. I am pretty sure WordPress can detect that a site is git managed, and disables auto-updates by default. This would be the preferred behavior. We do not want production files EVER changing on production with out going through the normal deployment process.
The page I need help with: [log in to see the link]
- The topic ‘Managing a WooCommerce site with Git’ is closed to new replies.