Multiple Storefront & Rebuild Cache Automatically

I noticed when I change Rebuild Cache Automatically it changes it for both storefronts. This is a pain when one site is Live and one is under development. Is this a bug or am I doing something wrong.

No, it's “working as designed”.

It is a global setting affecting admin, and all storefronts.

There might be a code modification you could do that would only activate it for one store, but I'm not sure the system will handle that properly since some things are global and some are not.

Thanks, that's what I was afraid of.

I would not recommend to change this behavior.

The point is that since 4.x if your storefronts use the same theme - all the compiled templates are the same.

If you have different themes for Live & Dev storefronts than you can just clear the compiled templates for Dev storefront using this command:

rm -rf ./var/cache/templates/DEV_THEME_NAME