10up / generator-wp-make

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

Git clone vs npm install, and version discrepancies #84

Closed MickeyKay closed 8 years ago

MickeyKay commented 8 years ago

First off, fantastic project. Love it!

Secondly, I realize the readme install instructions suggest cloning with a subsequent npm link, so I'm curious if there is a reason why the npm package is no longer the condoned method for install (e.g. npm install -g generator-wp-make) . The npm package still appears to be published there, https://www.npmjs.com/package/generator-wp-make, however the version listed there is 0.4.3 while the latest release tagged in git is 0.4.2.

Additionally, when I install via npm and try to run yo wp-make:theme, I get the following:

› yo wp-make:theme
Error wp-make:theme

You don't seem to have a generator with the name wp-make:theme installed.
You can see available generators with npm search yeoman-generator and then install them with npm install [name].
To see the 9 registered generators run yo with the `--help` option.

Any ideas? Thanks!

arulpr commented 8 years ago

Actually the git clone doesn't have a file structure of a yeoman generator. Just download the latest release to any directory and

cd directory

now run the command

npm link

this will create a global symlink in NPM. Now if you run

yo --generators you should see the wp-make and its sub generators listed

allenmoore commented 8 years ago

Hey @MickeyKay,

Thank you for making us aware of this issue. After testing, I discovered that when files: {} is declared in package.json, npm will only install the files listed in that declaration. I've created a pull request with this fix -- https://github.com/10up/generator-wp-make/pull/88.

Thank you, Allen Moore

allenmoore commented 8 years ago

Hey @MickeyKay

The previously mentioned pull requested has been merged to master and has also been published to npm. I've tested the latest release locally and all of the sub-generators listed as available when running yo --help. I've also verified that each of the sub-generators run when called. I'm going to close this issue and consider this to be resolved. Please let us know if you have any additional concerns or issues.

Thank you, Allen Moore

RachelRVasquez commented 8 years ago

Hi @allenmoore I'm setting up WP Make for the first time locally and experiencing this issue with the "You don't seem to have a generator with the name wp-make:theme installed." message. I've installed a generator using npm install -g generator-webapp or npm install generator-angular and neither seem to be clearing up the issue for me. Any steps I could be missing?