diff --git a/bin/templates/scripts/cordova/lib/build.js b/bin/templates/scripts/cordova/lib/build.js index a72038756..ddcc4b6d0 100644 --- a/bin/templates/scripts/cordova/lib/build.js +++ b/bin/templates/scripts/cordova/lib/build.js @@ -71,6 +71,7 @@ function createProjectObject (projectPath, projectName) { * @return {Promise} */ function getDefaultSimulatorTarget () { + events.emit('log', 'Select last emulator from list as default.'); return require('./listEmulatorBuildTargets').run() .then(emulators => { let targetEmulator; diff --git a/bin/templates/scripts/cordova/lib/listEmulatorBuildTargets.js b/bin/templates/scripts/cordova/lib/listEmulatorBuildTargets.js index 73e35c05a..5b1bc2a78 100644 --- a/bin/templates/scripts/cordova/lib/listEmulatorBuildTargets.js +++ b/bin/templates/scripts/cordova/lib/listEmulatorBuildTargets.js @@ -17,7 +17,7 @@ under the License. */ -const { superspawn: { spawn } } = require('cordova-common'); +const { superspawn: { spawn }, events } = require('cordova-common'); /** * Returns a list of available simulator build targets of the form @@ -31,7 +31,8 @@ const { superspawn: { spawn } } = require('cordova-common'); * */ function listEmulatorBuildTargets () { - return spawn('xcrun', ['simctl', 'list', '--json']) + events.emit('log', 'List simulator targets'); + return spawn('xcrun', ['simctl', 'list', '--json'], { printCommand: true }) .then(output => JSON.parse(output)) .then(function (simInfo) { var devices = simInfo.devices;