yeswework / fabrica-dev-kit

A toolkit for faster, smoother WordPress 5 development
https://fabri.ca/
MIT License
274 stars 27 forks source link

Error when trying to setup the project with 'fdk setup' command #41

Closed shivanibisht closed 3 years ago

shivanibisht commented 3 years ago

I'm trying to setup the local development environment after creating and editing the setup.yml file as per the documentation. But when I run 'fdk setup' it throws the following error:

[Fabrica] 🏭 Reading settings... undefined:6 "author": undefined, ^

SyntaxError: Unexpected token u in JSON at position 90 at JSON.parse () at createFolders (/usr/local/lib/node_modules/fabrica-dev-kit/index.js:165:30) at Command.setup (/usr/local/lib/node_modules/fabrica-dev-kit/index.js:350:2) at Command.listener (/usr/local/lib/node_modules/fabrica-dev-kit/node_modules/commander/index.js:315:8) at Command.emit (events.js:198:13) at Command.parseArgs (/usr/local/lib/node_modules/fabrica-dev-kit/node_modules/commander/index.js:651:12) at Command.parse (/usr/local/lib/node_modules/fabrica-dev-kit/node_modules/commander/index.js:474:21) at Object. (/usr/local/lib/node_modules/fabrica-dev-kit/index.js:411:9) at Module._compile (internal/modules/cjs/loader.js:778:30) at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)

Any help with this will be really appreciated. Thanks

andrewstaffell commented 3 years ago

I think this happens when the local resource (theme / plugin) paths in config.yml are missing or incorrect. What does your config.yml file look like?

shivanibisht commented 3 years ago

Actually, the issue was with the package.json file, it named author as undefined without quotes. Resolved now, Thanks.

andrewstaffell commented 3 years ago

Ah, OK. Great, glad it's resolved.