Fresh clone gives error when running `npm start`
Magneticmagnum opened this issue · 9 comments
I'm on a Windows 7 Machine and followed the Readme's commands.
Node version: 6.9.1
After npm start
I get the following:
$ npm start
relay-fullstack@1.0.0 start c:\dev\relay-fullstack
nodemon --watch server/data/**/*.js --exec "npm run update && ./node_modules/.bin/babel-node server/index.js"[nodemon] 1.11.0
[nodemon] to restart at any time, enterrs
[nodemon] watching: server/data/**/*.js
[nodemon] startingnpm run update && ./node_modules/.bin/babel-node server/index.js
relay-fullstack@1.0.0 update c:\dev\relay-fullstack
babel-node server/utils/updateSchema.jsSchema has been regenerated
'.' is not recognized as an internal or external command,
operable program or batch file.
[nodemon] app crashed - waiting for file changes before starting...
Nevermind, I was able to run the start script commands individually...
For those reading this, it seems to be a pathing issue with Node and Windows. Try running the npm start commands seperately:
nodemon --watch server/data/**/*.js --exec \"npm run update
./node_modules/.bin/babel-node server/index.js\
Just to add to this. It appears its because of the inner string. You could change it to this
"start": "nodemon --watch server/data/**/*.js --exec \"npm run update && npm run start-sub-task\"", "start-sub-task": "./node_modules/.bin/babel-node server/index.js",
Then it all works
Thanks @Magneticmagnum , @Jordan-Hall for sharing the solutions.
Might be a good idea if @Jordan-Hall's fix made it into the code base (I don't have a non-windows machine to test on).
If I wasn't so stubborn I would have just bounced off this error the first time I ran into it :)
Odd, I did a fresh pull this morning and got the error above. Jordan's solution fixed it.
Then, if you could test the solution and send a PR, that would be awesome.
Done!