Skip to content

Commit

Permalink
Merge pull request #179 from zypo/master
Browse files Browse the repository at this point in the history
Add option to deploy to specific emulator target/image for platforms
  • Loading branch information
BryanH committed Jan 21, 2016
2 parents be9067d + 032b59a commit 285f5e5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
8 changes: 8 additions & 0 deletions docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,14 @@ ENV.cordova = {
// default: false
emulate: true,

// Which emulated target to deploy to
//
// default: <system default>
emulateTarget: {
ios: "iPad-2",
android: "android-20"
}

// Which platform to build and/or emulate
//
// default: 'ios'
Expand Down
6 changes: 6 additions & 0 deletions lib/tasks/post-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ function createCommand(project, options) {

if (options.emulate) {
command += ' && cordova emulate ' + platform;

if (options.emulateTarget) {
if (options.emulateTarget[platform]) {
command += ' --target="' + options.emulateTarget[platform] + '"';
}
}
}

return runCommand(command, null, {
Expand Down

0 comments on commit 285f5e5

Please sign in to comment.