Comparing version 0.9.3 to 0.9.4
@@ -69,2 +69,3 @@ #!/usr/bin/env node | ||
plugman.on('error', console.error); | ||
plugman.on('results', console.log); | ||
@@ -71,0 +72,0 @@ if (cli_opts.v) { |
@@ -5,3 +5,3 @@ { | ||
"description": "install/uninstall Cordova plugins", | ||
"version": "0.9.3", | ||
"version": "0.9.4", | ||
"repository": { | ||
@@ -71,4 +71,7 @@ "type": "git", | ||
"name":"Michael Brooks" | ||
}, | ||
{ | ||
"name":"Jesse MacFadyen" | ||
} | ||
] | ||
} |
@@ -26,3 +26,3 @@ # plugman | ||
* BlackBerry 10 | ||
* Windows Phone 7 | ||
* Windows Phone (7+8) | ||
@@ -29,0 +29,0 @@ ## Command Line Usage |
@@ -61,3 +61,3 @@ var install = require('../src/install'), | ||
install('android', temp, dummyplugin, plugins_dir, {}); | ||
expect(spy).toHaveBeenCalledWith('log', 'Plugin "'+dummy_id+'" already installed, \'sall good.'); | ||
expect(spy).toHaveBeenCalledWith('results', 'Plugin "'+dummy_id+'" already installed, \'sall good.'); | ||
}); | ||
@@ -64,0 +64,0 @@ it('should check version if plugin has engine tag', function(){ |
@@ -40,6 +40,2 @@ var platforms = require('../src/platforms'), | ||
}); | ||
it('should create a cordova_plugins.json file', function() { | ||
prepare(temp, 'android', plugins_dir); | ||
expect(write).toHaveBeenCalledWith(json, jasmine.any(String), 'utf-8'); | ||
}); | ||
it('should create a cordova_plugins.js file', function() { | ||
@@ -46,0 +42,0 @@ prepare(temp, 'android', plugins_dir); |
@@ -91,3 +91,3 @@ var path = require('path'), | ||
if (is_installed) { | ||
require('../plugman').emit('log', 'Plugin "' + plugin_id + '" already installed, \'sall good.'); | ||
require('../plugman').emit('results', 'Plugin "' + plugin_id + '" already installed, \'sall good.'); | ||
if (callback) callback(); | ||
@@ -296,3 +296,3 @@ return; | ||
require('../plugman').emit('log', plugin_id + ' installed.'); | ||
require('../plugman').emit('results', plugin_id + ' installed.'); | ||
if (callback) callback(); | ||
@@ -299,0 +299,0 @@ } |
@@ -142,12 +142,7 @@ /** | ||
require('../plugman').emit('log', 'Writing out cordova_plugins.json...'); | ||
// Write out moduleObjects as JSON to cordova_plugins.json | ||
fs.writeFileSync(path.join(wwwDir, 'cordova_plugins.json'), JSON.stringify(moduleObjects), 'utf-8'); | ||
// Write out moduleObjects as JSON wrapped in a cordova module to cordova_plugins.js | ||
// This is to support Windows Phone platforms that have trouble with XHR during load | ||
var final_contents = "cordova.define('cordova/plugin_list', function(require, exports, module) {\n"; | ||
final_contents += 'module.exports = ' + JSON.stringify(moduleObjects) + '\n'; | ||
final_contents += '});'; | ||
final_contents += 'module.exports = ' + JSON.stringify(moduleObjects,null,' ') + '\n});'; | ||
require('../plugman').emit('log', 'Writing out cordova_plugins.js...'); | ||
fs.writeFileSync(path.join(wwwDir, 'cordova_plugins.js'), final_contents, 'utf-8'); | ||
}; |
@@ -71,3 +71,3 @@ var path = require('path'), | ||
shell.rm('-rf', plugin_dir); | ||
require('../plugman').emit('log', id + ' removed.'); | ||
require('../plugman').emit('results', 'Deleted "' + plugin_dir + '".'); | ||
if (callback) callback(); | ||
@@ -171,2 +171,3 @@ } | ||
// WIN! | ||
require('../plugman').emit('results', plugin_id + ' uninstalled.'); | ||
// queue up the plugin so prepare can remove the config changes | ||
@@ -173,0 +174,0 @@ config_changes.add_uninstalled_plugin_to_prepare_queue(plugins_dir, path.basename(plugin_dir), platform, is_top_level); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
2690565
10509