Many guides I read state just running setup:upgrade or clearing the cache will result in changes to modules being made apparent, but if I just clear the cache it doesn't help, even if I delete all the files in the var/generation and var/page_cache and var/di and var/cache folders and run magento cache:clean. Running magento setup:upgrade break the site, no js or css is there at all unless I rerun setup:di:compile and setup:static-content:deploy yet the site is in development mode with caching disabled, so why do I have to re compile and re deploy for every change to a module? It seems broken :( Especially as all these guides say just setup:upgrade or cache:clean should show my changes, which I'm not understanding why need run if I'm in development mode with cache disabled? Any help greatly appreciated, waiting to redeploy for any change I want to see is very time consuming.
setup:upgrade : If you enabled one or more modules, then you will need to run magento setup:upgrade to update the database schema.
Setup:upgrade : it not require run on every changes in module.
cache:clean : if it enable from admin then you have to clean after any changes in code, but if it disable from admin then no need to run cache:clean command.
When we run setup:upgrade command after that we have to deploy static content, else no need to deploy static content.
I found an answer finally. My server uses php-fpm and there was something weird with it not setting developer mode properly this page helped me: How do I set Developer Mode in Magento 2
As did the people on this page so upvoted them :) The post that helped me the most was setting developer mode in the php-fpm pool. I also have to restart php-fpm service on each change but it then shows up immediately, even if I don't run cache:clean. So I'll need to fix something with php-fpm but this is not a magento issue and you guys helped me so thank you.
To further this, to fix it totally I had to set these in a php.ini file for me this was in /etc/php.d/10-opcache.ini
opcache.enable = 0 opcache.enable_cli = 0
and for the environment variable in /etc/php-fpm.d/www.conf
env[MAGE_MODE] = developer
Then restarting php-fpm
service php-fpm restart
And my changes to phtml files show up immediately now.