Comments (10)
Is there any other watchers or grunt files running? At the watcher stage there shouldn't be anything involved with the plugin (i.e grunt-contrib-watch is being on the app folder so should never touch the src
folder) from that setup
from grunt-shopify.
It's the only watch and Gruntfile running. But if you look at the terminal screenshot, you can see that the first upload is from the src folder and the second is from the app folder. Everything runs smoothly if I remove the grunt-contrib-copy from the Gruntfile.
from grunt-shopify.
I'm seeing the same issue as well. I'm working out of a shop
folder and then using ryanburnette/grunt-shopify-theme to copy over the necessary files to a dist
folder. According to my terminal output grunt-shopify
uploads the changed file from shop
first then after grunt-shopify-theme
runs grunt-shopify
again uploads the changed file from dist
.
from grunt-shopify.
Since grunt-shopify-theme also uses grunt-contrib-copy I tested disabling that task and when I did only one upload happened on change. So maybe some sort of conflict with grunt-contrib-copy triggers the first erroneous upload?
from grunt-shopify.
@farneman exactly! grunt-shopify trigger before other tasks defined in watch.
from grunt-shopify.
Same issue here. Overall it works well and files get uploaded, just 5% weird that its trying to upload initially on a file save from a directory not specified in the files array, seemingly out of turn. Don't have a solution and this won't stop my enjoyment of the plugin, but any insight would be much appreciated :) All plays well when not combined with another task that uses watch, in this case grunt-contrib-sass. Here's a screengrab and my watch for good measure:
watch: {
css: {
files: ['_sass/**/*.scss'],
tasks: ['sass','cssc'],
options: {
spawn: false,
}
},
shopify: {
files: ['theme/assets/**','theme/config/**','theme/layout/**','theme/snippets/**','theme/templates/**'],
tasks: ["shopify"]
}
}
Edit: https://github.com/erickreutz/grunt-shopify this version fixes the multiple upload issue for me. Sorry if I jumped the gun, new to this plugin. Thanks so much all for the great work. Cheers!
from grunt-shopify.
I believe the issue is that the watch event doesn't respect which target. now v0.5 of watch does include the target as an arg so we may be use that but my latest changes should also prevent from uploading anything not in base path (which is cwd if not using a base)
from grunt-shopify.
I think this is the commit that fixes it: erickreutz@39c29e8?w=1
I'm getting a similar bug.
It's great that it's letting me know that that file isn't allowed, but it shouldn't really be checking outside of the folders I declare for it to watch anyways.
watch:
styles:
files: ["styles/*"]
tasks: ["concat"]
shopify:
files: ["assets/*","config/*","layout/*","snippets/*","templates/*"]
tasks: ["shopify"]
from grunt-shopify.
Agreed with Gray above. No need to watch/notify me of files outside those declared in files
.
from grunt-shopify.
Should now be resolved.
from grunt-shopify.
Related Issues (20)
- Livereload is trigger prematurely HOT 4
- Watch doesn't detect addition / deletion of files HOT 2
- Task doesn't do anything... HOT 2
- I keep getting this error: Loading "shopify.js" tasks...ERROR
- shopify watch errors HOT 2
- grunt watch:shopify not publishing despite successful status report HOT 6
- Shopify:Download grunt task not working HOT 1
- Updating just changed files? HOT 1
- Gulp equivalent of grunt-shopify HOT 2
- Download is throttled HOT 2
- not in base path HOT 2
- watch stopped working shopify:upload still works HOT 2
- Deploy without images
- New 'Sections' feature in themes HOT 2
- Suggestion: Ignore settings_data.json setting HOT 1
- "Loading "shopify.js" tasks...ERROR" after updating to 1.0.1 from 1.0.0 HOT 1
- Cannot find module growl HOT 2
- Getting upload errors for the "assets" folder
- Not allowed by Shopify whitelist HOT 1
- Request limit exceeded for the Shopify API Use HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from grunt-shopify.