MCPcopy
hub / github.com/meteor/meteor / listInstalledPluginVersions

Method listInstalledPluginVersions

tools/cordova/project.js:472–483  ·  view source on GitHub ↗
(usePluginInfoId = false)

Source from the content-addressed store, hash-verified

470 // So we overwrite the declared versions with versions from
471 // listFetchedPluginVersions that do contain this information.
472 listInstalledPluginVersions(usePluginInfoId = false) {
473 const pluginInfoProvider = new PluginInfoProvider();
474 const installedPluginVersions = pluginInfoProvider.getAllWithinSearchPath(
475 files.convertToOSPath(this.pluginsDir));
476 const fetchedPluginVersions = this.listFetchedPluginVersions();
477 return _.object(installedPluginVersions.map(pluginInfo => {
478 const fetchedPlugin = fetchedPluginVersions[pluginInfo.id];
479 const id = fetchedPlugin.id;
480 const version = fetchedPlugin.version || pluginInfo.version;
481 return [usePluginInfoId ? pluginInfo.id : id, version];
482 }));
483 }
484
485 // There is no Cordova function to get the fetched plugin versions, so we
486 // have to read in fetch.json (a file managed by plugman, a semi-independent

Callers 2

Calls 2

mapMethod · 0.80

Tested by

no test coverage detected