wilr / grunt-shopify

Grunt plug-in for publishing Shopify theme assets
BSD 3-Clause "New" or "Revised" License
107 stars 32 forks source link

Task doesn't do anything... #49

Closed dominikwilkowski closed 9 years ago

dominikwilkowski commented 9 years ago

Hi there,

I would love to use this plugin but I don't seem to be able to get it to run.

this is my grunt task:

        shopify: {
            options: {
                api_key: '<%= shpfy.api_key %>',
                password: '<%= shpfy.password %>',
                url: '<%= shpfy.url %>',
                theme: '<%= shpfy.theme %>',
                base: './shopify/',
            },
        },

this is my watch:

            shopify: {
                files: [
                    './shopify/assets/**',
                    './shopify/config/**',
                    './shopify/snippets/**',
                    './shopify/layout/**',
                    './shopify/templates/**',
                ],
                tasks: [
                    'shopify',
                ],
            },

And this is the output I get:

>> File "shopify/assets/BSBLSC.0.0.1.min.css" changed.
Running "shopify" task

Done, without errors.

When I run grunt shopify:upload I get this:

Running "shopify:upload" task
>> [grunt-shopify] - Uploading "assets/BSBLSC.0.0.1.min.css"
>> [grunt-shopify] - File "assets/BSBLSC.0.0.1.min.css" uploaded.
>> [grunt-shopify] - Uploading "assets/BSBLSC.0.0.1.min.js"
>> [grunt-shopify] - File "assets/BSBLSC.0.0.1.min.js" uploaded.
>> [grunt-shopify] - Theme deploy complete.

Btw I am using a very fresh and updated node install. (Might be a new version that breaks compatibility?)

Any idea?

dominikwilkowski commented 9 years ago

I found the reason why the watch failed:

            shopify: {
                files: [
                    'shopify/assets/**',
                    'shopify/config/**',
                    'shopify/snippets/**',
                    'shopify/layout/**',
                    'shopify/templates/**',
                ],
                tasks: [
                    'shopify',
                ],
            },

The path cannot have ./ prepended to it. Removing it worked.

Hope this helps someone else ;)

ryanburnette commented 9 years ago

👏