Closed quaninte closed 9 years ago
Hey @quaninte, author of the theme settings plugin here.
Can you please provide the version of Ubuntu and Node.js you're running and the output of node ls
?
@gavinballard Thanks for the help, here is output
nodejs -v
v0.10.33
lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04 LTS
Release: 14.04
Codename: trusty
## Error with `node ls`
root@qdev:~# node ls
module.js:340
throw err;
^
Error: Cannot find module '/root/ls'
at Function.Module._resolveFilename (module.js:338:15)
at Function.Module._load (module.js:280:25)
at Function.Module.runMain (module.js:497:10)
at startup (node.js:119:16)
at node.js:906:3
Whoops, sorry, that should have been a request for npm ls
, not node ls
.
Could also please show the output when you run grunt shopify_theme_settings --verbose
? Just want to make sure I can recreate this problem before I get stuck in to it :).
@gavinballard here you go:
brodev@qdev:~/sites/bootstrapify$ grunt shopify_theme_settings --verbose
Initializing
Command-line options: --verbose
Reading "Gruntfile.js" Gruntfile...OK
Registering Gruntfile tasks.
Initializing config...OK
Registering "grunt-contrib-jshint" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-jshint/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-jshint/package.json...OK
Loading "jshint.js" tasks...OK
+ jshint
Registering "grunt-contrib-uglify" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-uglify/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-uglify/package.json...OK
Loading "uglify.js" tasks...OK
+ uglify
Registering "grunt-contrib-watch" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-watch/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-watch/package.json...OK
Loading "watch.js" tasks...OK
+ watch
Registering "grunt-contrib-sass" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-sass/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-sass/package.json...OK
Loading "sass.js" tasks...OK
+ sass
Registering "grunt-contrib-copy" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-copy/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-copy/package.json...OK
Loading "copy.js" tasks...OK
+ copy
Registering "grunt-contrib-concat" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-concat/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-concat/package.json...OK
Loading "concat.js" tasks...OK
+ concat
Registering "grunt-contrib-compress" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-compress/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-contrib-compress/package.json...OK
Loading "compress.js" tasks...OK
+ compress
Registering "grunt-shopify-theme-settings" local Npm module tasks.
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/package.json...OK
Parsing /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/package.json...OK
Loading "shopify_import_theme_settings.js" tasks...OK
+ shopify_import_theme_settings
Loading "shopify_theme_settings.js" tasks...OK
+ shopify_theme_settings
Loading "Gruntfile.js" tasks...OK
+ default
Running tasks: shopify_theme_settings
Running "shopify_theme_settings" task
Running "shopify_theme_settings:settings" (shopify_theme_settings) task
Verifying property shopify_theme_settings.settings exists in config...OK
Files: settings/branding.yml, settings/colour.yml, settings/design.yml, settings/layout.yml, settings/homepage.yml, settings/homepage-slider.yml, settings/typography.yml, settings/blog.yml, settings/products.yml, settings/collections.yml, settings/sidebar.yml, settings/navigation.yml, settings/footer.yml, settings/cart.yml, settings/age-verification.yml, settings/localization.yml, settings/money.yml, settings/social.yml, settings/advanced.yml -> theme/config/settings.html
Options: templates=["settings/templates"], tidyOptions={"docType":"strict","outputXhtml":true,"indent":true,"indentSpaces":4,"wrap":0,"showBodyOnly":true,"dropEmptyElements":false}
Reading settings/branding.yml...OK
Parsing settings/branding.yml...OK
Reading settings/colour.yml...OK
Parsing settings/colour.yml...OK
Reading settings/design.yml...OK
Parsing settings/design.yml...OK
Reading settings/layout.yml...OK
Parsing settings/layout.yml...OK
Reading settings/homepage.yml...OK
Parsing settings/homepage.yml...OK
Reading settings/homepage-slider.yml...OK
Parsing settings/homepage-slider.yml...OK
Reading settings/typography.yml...OK
Parsing settings/typography.yml...OK
Reading settings/blog.yml...OK
Parsing settings/blog.yml...OK
Reading settings/products.yml...OK
Parsing settings/products.yml...OK
Reading settings/collections.yml...OK
Parsing settings/collections.yml...OK
Reading settings/sidebar.yml...OK
Parsing settings/sidebar.yml...OK
Reading settings/navigation.yml...OK
Parsing settings/navigation.yml...OK
Reading settings/footer.yml...OK
Parsing settings/footer.yml...OK
Reading settings/cart.yml...OK
Parsing settings/cart.yml...OK
Reading settings/age-verification.yml...OK
Parsing settings/age-verification.yml...OK
Reading settings/localization.yml...OK
Parsing settings/localization.yml...OK
Reading settings/money.yml...OK
Parsing settings/money.yml...OK
Reading settings/social.yml...OK
Parsing settings/social.yml...OK
Reading settings/advanced.yml...OK
Parsing settings/advanced.yml...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/blog.html...OK
Writing /tmp/templates114103-10747-1f0o66i/blog.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/checkbox.html...OK
Writing /tmp/templates114103-10747-1f0o66i/checkbox.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/collection.html...OK
Writing /tmp/templates114103-10747-1f0o66i/collection.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/color.html...OK
Writing /tmp/templates114103-10747-1f0o66i/color.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/field.html...OK
Writing /tmp/templates114103-10747-1f0o66i/field.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/file.html...OK
Writing /tmp/templates114103-10747-1f0o66i/file.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/font.html...OK
Writing /tmp/templates114103-10747-1f0o66i/font.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/linklist.html...OK
Writing /tmp/templates114103-10747-1f0o66i/linklist.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/page.html...OK
Writing /tmp/templates114103-10747-1f0o66i/page.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/section.about.html...OK
Writing /tmp/templates114103-10747-1f0o66i/section.about.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/section.html...OK
Writing /tmp/templates114103-10747-1f0o66i/section.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/select.html...OK
Writing /tmp/templates114103-10747-1f0o66i/select.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/settings.html...OK
Writing /tmp/templates114103-10747-1f0o66i/settings.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/snippet.html...OK
Writing /tmp/templates114103-10747-1f0o66i/snippet.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/subsection.html...OK
Writing /tmp/templates114103-10747-1f0o66i/subsection.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/text-multi.html...OK
Writing /tmp/templates114103-10747-1f0o66i/text-multi.html...OK
Reading /home/brodev/sites/bootstrapify/node_modules/grunt-shopify-theme-settings/tasks/templates/text-single.html...OK
Writing /tmp/templates114103-10747-1f0o66i/text-single.html...OK
Reading settings/templates/display-location-field.html...OK
Writing /tmp/templates114103-10747-1f0o66i/display-location-field.html...OK
Fatal error: spawn ENOENT
# npm ls result
brodev@qdev:~/sites/bootstrapify$ npm ls
Bootstrapify@3.1.0 /home/brodev/sites/bootstrapify
├─┬ grunt@0.4.5
│ ├── async@0.1.22
│ ├── coffee-script@1.3.3
│ ├── colors@0.6.2
│ ├── dateformat@1.0.2-1.2.3
│ ├── eventemitter2@0.4.14
│ ├── exit@0.1.2
│ ├─┬ findup-sync@0.1.3
│ │ ├─┬ glob@3.2.11
│ │ │ ├── inherits@2.0.1
│ │ │ └─┬ minimatch@0.3.0
│ │ │ ├── lru-cache@2.5.0
│ │ │ └── sigmund@1.0.0
│ │ └── lodash@2.4.1
│ ├── getobject@0.1.0
│ ├─┬ glob@3.1.21
│ │ ├── graceful-fs@1.2.3
│ │ └── inherits@1.0.0
│ ├─┬ grunt-legacy-log@0.1.1
│ │ ├── lodash@2.4.1
│ │ └── underscore.string@2.3.3
│ ├── grunt-legacy-util@0.2.0
│ ├── hooker@0.2.3
│ ├── iconv-lite@0.2.11
│ ├─┬ js-yaml@2.0.5
│ │ ├─┬ argparse@0.1.15
│ │ │ ├── underscore@1.4.4
│ │ │ └── underscore.string@2.3.3
│ │ └── esprima@1.0.4
│ ├── lodash@0.9.2
│ ├─┬ minimatch@0.2.14
│ │ ├── lru-cache@2.5.0
│ │ └── sigmund@1.0.0
│ ├─┬ nopt@1.0.10
│ │ └── abbrev@1.0.5
│ ├── rimraf@2.2.8
│ ├── underscore.string@2.2.1
│ └── which@1.0.5
├─┬ grunt-contrib-compress@0.9.1
│ ├─┬ archiver@0.9.1
│ │ ├── buffer-crc32@0.2.3
│ │ ├─┬ file-utils@0.1.5
│ │ │ ├─┬ findup-sync@0.1.3
│ │ │ │ └── lodash@2.4.1
│ │ │ ├─┬ glob@3.2.11
│ │ │ │ ├── inherits@2.0.1
│ │ │ │ └─┬ minimatch@0.3.0
│ │ │ │ ├── lru-cache@2.5.0
│ │ │ │ └── sigmund@1.0.0
│ │ │ ├── iconv-lite@0.2.11
│ │ │ ├── isbinaryfile@0.1.9
│ │ │ ├── lodash@2.1.0
│ │ │ ├─┬ minimatch@0.2.14
│ │ │ │ ├── lru-cache@2.5.0
│ │ │ │ └── sigmund@1.0.0
│ │ │ └── rimraf@2.2.8
│ │ ├── lazystream@0.1.0
│ │ ├── lodash@2.4.1
│ │ ├─┬ readable-stream@1.0.33
│ │ │ ├── core-util-is@1.0.1
│ │ │ ├── inherits@2.0.1
│ │ │ ├── isarray@0.0.1
│ │ │ └── string_decoder@0.10.31
│ │ ├─┬ tar-stream@0.3.3
│ │ │ ├── bl@0.6.0
│ │ │ └─┬ end-of-stream@0.1.5
│ │ │ └─┬ once@1.3.1
│ │ │ └── wrappy@1.0.1
│ │ └─┬ zip-stream@0.3.7
│ │ ├── crc32-stream@0.2.0
│ │ ├─┬ debug@1.0.4
│ │ │ └── ms@0.6.2
│ │ └── deflate-crc32-stream@0.1.2
│ └── prettysize@0.0.3
├── grunt-contrib-concat@0.3.0
├── grunt-contrib-copy@0.5.0
├─┬ grunt-contrib-jshint@0.7.2
│ └─┬ jshint@2.3.0
│ ├─┬ cli@0.4.5
│ │ └─┬ glob@4.0.6
│ │ ├── graceful-fs@3.0.4
│ │ ├── inherits@2.0.1
│ │ ├─┬ minimatch@1.0.0
│ │ │ ├── lru-cache@2.5.0
│ │ │ └── sigmund@1.0.0
│ │ └─┬ once@1.3.1
│ │ └── wrappy@1.0.1
│ ├── console-browserify@0.1.6
│ ├─┬ minimatch@0.4.0
│ │ ├── lru-cache@2.5.0
│ │ └── sigmund@1.0.0
│ ├── shelljs@0.1.4
│ └── underscore@1.4.4
├─┬ grunt-contrib-sass@0.7.4
│ ├── async@0.9.0
│ ├─┬ chalk@0.5.1
│ │ ├── ansi-styles@1.1.0
│ │ ├── escape-string-regexp@1.0.2
│ │ ├─┬ has-ansi@0.1.0
│ │ │ └── ansi-regex@0.2.1
│ │ ├─┬ strip-ansi@0.3.0
│ │ │ └── ansi-regex@0.2.1
│ │ └── supports-color@0.2.0
│ ├── dargs@0.1.0
│ ├── which@1.0.5
│ └── win-spawn@2.0.0
├─┬ grunt-contrib-uglify@0.3.3
│ ├─┬ chalk@0.4.0
│ │ ├── ansi-styles@1.0.0
│ │ ├── has-color@0.1.7
│ │ └── strip-ansi@0.1.1
│ ├─┬ grunt-lib-contrib@0.6.1
│ │ └── zlib-browserify@0.0.1
│ └─┬ uglify-js@2.4.15
│ ├── async@0.2.10
│ ├─┬ optimist@0.3.7
│ │ └── wordwrap@0.0.2
│ ├─┬ source-map@0.1.34
│ │ └── amdefine@0.1.0
│ └── uglify-to-browserify@1.0.2
├─┬ grunt-contrib-watch@0.5.3
│ ├─┬ gaze@0.4.3
│ │ └─┬ globule@0.1.0
│ │ ├─┬ glob@3.1.21
│ │ │ ├── graceful-fs@1.2.3
│ │ │ └── inherits@1.0.0
│ │ ├── lodash@1.0.1
│ │ └─┬ minimatch@0.2.14
│ │ ├── lru-cache@2.5.0
│ │ └── sigmund@1.0.0
│ └─┬ tiny-lr@0.0.4
│ ├── debug@0.7.4
│ ├── faye-websocket@0.4.4
│ ├─┬ noptify@0.0.3
│ │ └─┬ nopt@2.0.0
│ │ └── abbrev@1.0.5
│ └── qs@0.5.6
└─┬ grunt-shopify-theme-settings@0.4.5
├─┬ cheerio@0.17.0
│ ├─┬ CSSselect@0.4.1
│ │ ├── CSSwhat@0.4.7
│ │ └─┬ domutils@1.4.3
│ │ └── domelementtype@1.1.3
│ ├─┬ dom-serializer@0.0.1
│ │ └── domelementtype@1.1.3
│ ├── entities@1.1.1
│ ├─┬ htmlparser2@3.7.3
│ │ ├── domelementtype@1.1.3
│ │ ├── domhandler@2.2.1
│ │ ├── domutils@1.5.0
│ │ ├── entities@1.0.0
│ │ └─┬ readable-stream@1.1.13
│ │ ├── core-util-is@1.0.1
│ │ ├── inherits@2.0.1
│ │ ├── isarray@0.0.1
│ │ └── string_decoder@0.10.31
│ └── lodash@2.4.1
├── htmltidy@0.0.6
├─┬ js-yaml@3.1.0
│ ├─┬ argparse@0.1.15
│ │ ├── underscore@1.4.4
│ │ └── underscore.string@2.3.3
│ └── esprima@1.0.4
├─┬ swig@1.4.2
│ ├─┬ optimist@0.6.1
│ │ ├── minimist@0.0.10
│ │ └── wordwrap@0.0.2
│ └─┬ uglify-js@2.4.15
│ ├── async@0.2.10
│ ├─┬ optimist@0.3.7
│ │ └── wordwrap@0.0.2
│ ├─┬ source-map@0.1.34
│ │ └── amdefine@0.1.0
│ └── uglify-to-browserify@1.0.2
└─┬ temp@0.8.1
└── rimraf@2.2.8
Thank you very much for your help.
Thanks for the info - I can reproduce this. Looks like an error in the grunt-shopify-theme-settings
plugin, so I'll dig in to that and report back here when that's fixed.
Okay, this is actually an error in the underlying htmltidy
node package, which the theme settings plugin uses to clean up the HTML it generates after use. See https://github.com/vavere/htmltidy/issues/11.
I'll keep an eye on that issue, but as the problem lies outside my plugin's code there's not a lot I can do directly I'm afraid.
Thanks, I've disabled settings build in Grunt for now
Hey @quaninte, I have noted this issue against the plugin repository and provided a pretty simple fix for it here: https://github.com/discolabs/grunt-shopify-theme-settings/issues/17.
After setup environment on ubuntu machine, I failed to build when running
grunt
command and got this errorHere is how I setup the env