MCPcopy Index your code
hub / github.com/ember-cli/ember-cli / _validateNpmModule

Method _validateNpmModule

lib/tasks/install-blueprint.js:185–191  ·  view source on GitHub ↗
(modulePath, packageName)

Source from the content-addressed store, hash-verified

183 }
184
185 _validateNpmModule(modulePath, packageName) {
186 logger.info(`Checking for "ember-blueprint" keyword in "${packageName}" module ...`);
187 let pkg = require(this._resolvePackageJSON(modulePath));
188 if (!pkg || !pkg.keywords || pkg.keywords.indexOf('ember-blueprint') === -1) {
189 throw new SilentError(`The package '${packageName}' is not a valid Ember CLI blueprint.`);
190 }
191 }
192
193 async _loadBlueprintFromPath(path) {
194 logger.info(`Loading blueprint from "${path}" ...`);

Callers 1

_tryRemoteBlueprintMethod · 0.95

Calls 1

_resolvePackageJSONMethod · 0.95

Tested by

no test coverage detected