10up / generator-wp-make

A Yeoman generator for making WordPress things
184 stars 42 forks source link

README instructions #106

Closed craigiswayne closed 7 years ago

craigiswayne commented 7 years ago

hey there, so followed your README to the 'T' and I was getting an error while trying to run:

yo wp-make

and found that i had to do

npm install -g extendable-yeoman

after doing

npm install -g yo

the error i was getting is shown below:

module.js:472
    throw err;
    ^

Error: Cannot find module 'extendable-yeoman'
    at Function.Module._resolveFilename (module.js:470:15)
    at Function.Module._load (module.js:418:25)
    at Module.require (module.js:498:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (/Users/jamesdean/.npm-packages/lib/node_modules/generator-wp-make/lib/generators/app/index.js:3:12)
    at Module._compile (module.js:571:32)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:488:32)
    at tryModuleLoad (module.js:447:12)
    at Function.Module._load (module.js:439:3)
allenmoore commented 7 years ago

Hey @craigiswayne,

Thanks for making us aware of this issue. Can you provide some additional information so that we can assist in determining what is causing this error?

Open your terminal app of choice and ensure the current working directory location is the home directory of your user account. You can run pwd to return the current working directory or run cd ~/ to change to the home directory of your user account.

Run the following commands:

npm list -g --depth=0
npm list --depth=0

Please paste the results from each command as a new comment.

Thank you, Allen Moore

craigiswayne commented 7 years ago

Sure... anything to help:

npm list -g --depth=0

/Users/ben10up/.npm-packages/lib
├── babel-cli@6.24.0
├── bower@1.8.0
├── extendable-yeoman@0.3.1
├── generator-wp-make@0.4.7
├── grunt@1.0.1
├── grunt-cli@1.2.0
├── grunt-run@0.6.0
├── gulp@3.9.1
├── node-sass@4.5.2
├── npm@4.4.4
├── orbweaver@0.1.3
├── typescript@2.2.2
└── yo@1.8.5

NOTE: the following command is run AFTER i successfully ran

yo wp-make:theme
npm list --depth=0
test-theme@0.1.0 /usr/local/var/www/wptest/wp-content/themes/test-theme
├── autoprefixer@6.7.7
├── chai@3.5.0
├── glob@5.0.15
├── grunt@0.4.5
├── grunt-contrib-clean@0.6.0
├── grunt-contrib-compress@0.13.0
├── grunt-contrib-concat@0.5.1
├── grunt-contrib-copy@0.8.2
├── grunt-contrib-cssmin@0.12.3
├── grunt-contrib-uglify@0.9.2
├── grunt-contrib-watch@0.6.1
├── grunt-eslint@18.1.0
├── grunt-jscs@2.8.0
├── grunt-mocha@1.0.4
├── grunt-phpunit@0.3.6
├── grunt-postcss@0.6.0
├── grunt-sass@1.2.1
├── load-grunt-config@0.17.2
└── load-grunt-tasks@3.5.2
craigiswayne commented 7 years ago

I should also mention that this is Mac OSX.

Installed node through Homebrew

allenmoore commented 7 years ago

Hey @craigiswayne,

Thank you for providing the info above. This could potentially be related to node being installed via Homebrew, which can introduce errors/issues with globally installed packages. Based on the issue you have experienced, and with WP-Make's dependency on the extendable-yeoman package, you may be experiencing an issue as mentioned above. Here's a gist that walks through a potential solution to resolve such an issue.

Thank you, Allen Moore

craigiswayne commented 7 years ago

Thanks for the feedback @allenmoore

Got it working already though.

You are welcome to close this.

Looking forward to playing around with this wp-make stuff

Cheers

allenmoore commented 7 years ago

Hey @craigiswayne,

Please let us know your thoughts! We are always interested in hearing from users of the generator, and their experiences using this.

Thank you, Allen Moore