Grunt dev failing

Hi, working on my first install of roots and I am getting an error when running grunt dev

Running "less:dev" (less) task
FileError: '../vendor/bootstrap/less/variables.less' wasn't found in assets/less/_bootstrap.less on line 8, column 1:
7 // Variables
8 @import "../vendor/bootstrap/less/variables";
Warning: Error compiling assets/less/main.less Use --force to continue.

Aborted due to warnings.

Please delete the node_modules dir inside your theme, then run npm install again. Paste the entire results here.

Thanks for the quick reply… here are the results of my npm install

npm WARN cannot run in wd roots@7.0.2 node node_modules/bower/bin/bower install && grunt dev (wd=/var/www/vhosts/
time-grunt@1.0.0 node_modules/time-grunt
├── date-time@1.0.0
├── figures@1.3.5
├── text-table@0.2.0
├── pretty-ms@1.0.0 (parse-ms@1.0.0, get-stdin@3.0.0)
├── hooker@0.2.3
└── chalk@0.5.1 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0, has-ansi@0.1.0, strip-ansi@0.3.0)

grunt-wp-assets@0.2.6 node_modules/grunt-wp-assets
└── async@0.6.2

grunt-contrib-concat@0.5.0 node_modules/grunt-contrib-concat
├── chalk@0.5.1 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0, strip-ansi@0.3.0, has-ansi@0.1.0)
└── source-map@0.1.40 (amdefine@0.1.0)

grunt-contrib-watch@0.6.1 node_modules/grunt-contrib-watch
├── async@0.2.10
├── tiny-lr-fork@0.0.5 (debug@0.7.4, faye-websocket@0.4.4, noptify@0.0.3, qs@0.5.6)
├── gaze@0.5.1 (globule@0.1.0)
└── lodash@2.4.1

load-grunt-tasks@1.0.0 node_modules/load-grunt-tasks
├── multimatch@1.0.0 (array-differ@1.0.0, array-union@1.0.1, minimatch@1.0.0)
└── findup-sync@0.1.3 (glob@3.2.11, lodash@2.4.1)

grunt@0.4.5 node_modules/grunt
├── dateformat@1.0.2-1.2.3
├── which@1.0.5
├── eventemitter2@0.4.14
├── getobject@0.1.0
├── rimraf@2.2.8
├── colors@0.6.2
├── async@0.1.22
├── grunt-legacy-util@0.2.0
├── hooker@0.2.3
├── nopt@1.0.10 (abbrev@1.0.5)
├── exit@0.1.2
├── minimatch@0.2.14 (sigmund@1.0.0, lru-cache@2.5.0)
├── glob@3.1.21 (inherits@1.0.0, graceful-fs@1.2.3)
├── lodash@0.9.2
├── coffee-script@1.3.3
├── underscore.string@2.2.1
├── iconv-lite@0.2.11
├── findup-sync@0.1.3 (glob@3.2.11, lodash@2.4.1)
├── grunt-legacy-log@0.1.1 (underscore.string@2.3.3, lodash@2.4.1)
└── js-yaml@2.0.5 (esprima@1.0.4, argparse@0.1.15)

grunt-modernizr@0.6.0 node_modules/grunt-modernizr
├── colors@0.6.2
├── promised-io@0.3.4
├── uglify-js@1.3.3
└── request@2.27.0 (json-stringify-safe@5.0.0, forever-agent@0.5.2, aws-sign@0.3.0, qs@0.6.6, tunnel-agent@0.3.0, oauth-sign@0.3.0, cookie-jar@0.3.0, node-uuid@1.4.1, mime@1.2.11, form-data@0.1.4, http-signature@0.10.0, hawk@1.0.0)

grunt-contrib-jshint@0.10.0 node_modules/grunt-contrib-jshint
├── hooker@0.2.3
└── jshint@2.5.10 (strip-json-comments@1.0.2, underscore@1.6.0, console-browserify@1.1.0, exit@0.1.2, minimatch@1.0.0, shelljs@0.3.0, cli@0.6.5, htmlparser2@3.8.2)

grunt-contrib-uglify@0.6.0 node_modules/grunt-contrib-uglify
├── uri-path@0.0.2
├── chalk@0.5.1 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0, strip-ansi@0.3.0, has-ansi@0.1.0)
├── uglify-js@2.4.15 (uglify-to-browserify@1.0.2, async@0.2.10, optimist@0.3.7, source-map@0.1.34)
├── lodash@2.4.1
└── maxmin@1.0.0 (figures@1.3.5, pretty-bytes@1.0.1, gzip-size@1.0.0)

grunt-autoprefixer@1.0.1 node_modules/grunt-autoprefixer
├── diff@1.0.8
├── chalk@0.5.1 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0, strip-ansi@0.3.0, has-ansi@0.1.0)
└── autoprefixer-core@3.1.2 (postcss@2.2.6, caniuse-db@1.0.30000025)

bower@1.3.12 node_modules/bower
├── is-root@1.0.0
├── junk@1.0.0
├── stringify-object@1.0.0
├── abbrev@1.0.5
├── chmodr@0.1.0
├── which@1.0.5
├── osenv@0.1.0
├── opn@1.0.0
├── archy@0.0.2
├── rimraf@2.2.8
├── lru-cache@2.5.0
├── bower-logger@0.2.2
├── bower-endpoint-parser@0.2.2
├── graceful-fs@3.0.4
├── lockfile@1.0.0
├── nopt@3.0.1
├── retry@0.6.0
├── tmp@0.0.23
├── request-progress@0.3.0 (throttleit@0.0.2)
├── q@1.0.1
├── chalk@0.5.0 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0, strip-ansi@0.3.0, has-ansi@0.1.0)
├── bower-json@0.4.0 (intersect@0.0.3, deep-extend@0.2.11, graceful-fs@2.0.3)
├── shell-quote@1.4.2 (array-filter@0.0.1, array-reduce@0.0.0, array-map@0.0.0, jsonify@0.0.0)
├── semver@2.3.2
├── fstream@1.0.2 (inherits@2.0.1)
├── p-throttler@0.1.0 (q@0.9.7)
├── promptly@0.2.0 (read@1.0.5)
├── mkdirp@0.5.0 (minimist@0.0.8)
├── fstream-ignore@1.0.1 (inherits@2.0.1, minimatch@1.0.0)
├── bower-config@0.5.2 (osenv@0.0.3, graceful-fs@2.0.3, optimist@0.6.1)
├── tar-fs@0.5.2 (pump@0.3.5, tar-stream@0.4.7)
├── decompress-zip@0.0.8 (nopt@2.2.1, mkpath@0.1.0, touch@0.0.2, readable-stream@1.1.13, binary@0.3.0)
├── request@2.42.0 (caseless@0.6.0, json-stringify-safe@5.0.0, forever-agent@0.5.2, aws-sign2@0.5.0, stringstream@0.0.4, oauth-sign@0.4.0, tunnel-agent@0.4.0, node-uuid@1.4.1, qs@1.2.2, mime-types@1.0.2, form-data@0.1.4, bl@0.9.3, tough-cookie@0.12.1, http-signature@0.10.0, hawk@1.1.1)
├── glob@4.0.6 (inherits@2.0.1, once@1.3.1, minimatch@1.0.0)
├── cardinal@0.4.0 (redeyed@0.4.4)
├── bower-registry-client@0.2.1 (graceful-fs@2.0.3, request-replay@0.2.0, lru-cache@2.3.1, async@0.2.10, mkdirp@0.3.5, request@2.27.0)
├── update-notifier@0.2.0 (semver-diff@0.1.0, string-length@0.1.2, latest-version@0.2.0, configstore@0.3.1)
├── mout@0.9.1
├── handlebars@2.0.0 (optimist@0.3.7, uglify-js@2.3.6)
├── inquirer@0.7.1 (figures@1.3.5, mute-stream@0.0.4, through@2.3.6, readline2@0.1.0, lodash@2.4.1, cli-color@0.3.2, rx@2.3.18)
└── insight@0.4.3 (object-assign@1.0.0, chalk@0.5.1, async@0.9.0, lodash.debounce@2.4.1, os-name@1.0.1, tough-cookie@0.12.1, configstore@0.3.1, inquirer@0.6.0)

grunt-contrib-less@0.12.0 node_modules/grunt-contrib-less
├── async@0.2.10
├── chalk@0.5.1 (escape-string-regexp@1.0.2, ansi-styles@1.1.0, supports-color@0.2.0, has-ansi@0.1.0, strip-ansi@0.3.0)
├── maxmin@0.1.0 (pretty-bytes@0.1.2, chalk@0.4.0, gzip-size@0.1.1)
├── lodash@2.4.1
└── less@1.7.5 (graceful-fs@3.0.4, mime@1.2.11, mkdirp@0.5.0, clean-css@2.2.19, source-map@0.1.40, request@2.40.0)

See here, here, here, and here.

When I ran npm install --unsafe-perm I received. Looking at the other links now

roots@7.0.2 postinstall /var/www/vhosts/
node node_modules/bower/bin/bower install && grunt dev
bower ESUDO Cannot be run with sudo

Was just able to get bower install with bower install --allow-root option. Pasted the results below, because still getting the same error on grunt dev

[?] May bower anonymously report usage statistics to improve the tool over time? No
bower bootstrap#3.3.1 not-cached git://
bower bootstrap#3.3.1 resolve git://
bower respond#1.4.2 not-cached git://
bower respond#1.4.2 resolve git://
bower modernizr#2.8.2 not-cached git://
bower modernizr#2.8.2 resolve git://
bower jquery#1.11.1 not-cached git://
bower jquery#1.11.1 resolve git://
bower respond#1.4.2 download
bower bootstrap#3.3.1 download
bower modernizr#2.8.2 download
bower jquery#1.11.1 download
bower respond#1.4.2 extract archive.tar.gz
bower modernizr#2.8.2 extract archive.tar.gz
bower jquery#1.11.1 extract archive.tar.gz
bower bootstrap#3.3.1 extract archive.tar.gz
bower respond#1.4.2 resolved git://
bower modernizr#2.8.2 invalid-meta modernizr is missing “main” entry in bower.json
bower modernizr#2.8.2 invalid-meta modernizr is missing “ignore” entry in bower.json
bower modernizr#2.8.2 resolved git://
bower jquery#1.11.1 resolved git://
bower bootstrap#3.3.1 resolved git://
bower ENOTFOUND Package option not found

Also just noticed the comment about errors possibly occurring when installing as root user so I uninstalled and started over again from another user. But when I ran sudo npm install I get

sudo: npm: command not found

After some reading about this, does this mean I may have a problem with my node install itself?

Corrected my problem with

That allowed me to install bower not as root and as a result fixed my error upon using grunt dev.

I guess this leads me to wondering why when I run grunt dev I am getting missing assets since the theme is looking for all of the minified versions of my css & js? I was assuming this would be handled correctly when I added define(‘WP_ENV’, ‘development’); to my config file, but that doesn’t seem to work the way I was expecting.

Thanks in advance.

Thanks for posting your solution @rydonahue

Yep. grunt dev is for your development environment, grunt build is for production, so if you’ve never generated a build using grunt build, your files don’t exists, which is why they’re missing. You’ve got to change the WP_ENV to dev if you want to see the results of grunt dev, hope that makes sense.