Skip to content

Commit 025c606

Browse files
committed
fix(cli): "open" command does not need to show device selector if only one is available (as like capacitor does)
1 parent cb44be3 commit 025c606

File tree

1 file changed

+3
-1
lines changed
  • packages/@ionic/cli/src/commands/capacitor

1 file changed

+3
-1
lines changed

packages/@ionic/cli/src/commands/capacitor/run.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,9 @@ For Android and iOS, you can setup Remote Debugging on your device with browser
205205
);
206206
}
207207
} else {
208-
if (targets.length > 0) {
208+
if (targets.length === 1) {
209+
options['target'] = targets[0].id;
210+
} else if (targets.length > 1) {
209211
options['target'] = await this.env.prompt({
210212
type: 'list',
211213
name: 'target',

0 commit comments

Comments
 (0)