-
Notifications
You must be signed in to change notification settings - Fork 869
npm run production watches files #745
Comments
Does it work if you wrap the watch tasks in the default task in a !isProduction condition?
|
No it does't. I've also tried moving the
with no luck. |
The way we got around this was to set a separate gulp task such as
Where the setEnvProd method sets the flag for production. The npm run production script is changed to 'gulp production'. |
I agree that |
I need to finish a site that I have been working on. Is there a working fix to run production, or a workaround? I have used an earlier version of foundationpress (v2.4.0) and had no issues with this. Thanks |
Still nothing here? |
@dDondero I am having the same problem. Did you ever solve this? |
I haven't had time to make a commit with the workaround. Feel free to take the pointers we've made and roll your own. We've moved to an alternate starter theme so I haven't been as motivated to extract our solution into a commit. |
Sorry @wjdennen, I don't have much experience with gulp/node so I weren't able to troubleshoot. I'm still waiting for an working update. I was able to run "npm run build", and then I copied over the files I needed for the theme to work. It's not optimal, performance-wise, but it's working. It's too bad there isn't a "stable" version of FP, and a few more updates (at least for errors/bugs). I'm reluctant on basing my projects on it because of this. @jpresley23 what starter-theme did you go for? Still Foundation-based? |
@dDondero : This seems to work:
|
Haha, @wjdennen well this helped me out a great deal. Thanks. The earlier version of FoundationPress I used created a new theme-folder with only the files needed, but that doesn't matter as long as the published site is working as it should. You can check out my project here if you'd like: ikuben.no Pretty simple looking, but there are a total of 8 custom post types for different content types and other customization. |
@wjdennen has the correct solution to this.
I think the best way to fix this would be to change the ...and then just remove the |
I'm setting up a build script for production for our project and used 'npm run production' as instructed README.md. I've noticed that results in watching files. Is there a way to use 'npm run production' without watching files? I also noticed that http://localhost:3000 is automatically opened in the browser, which is also not desirable for a production build.
The text was updated successfully, but these errors were encountered: