Skip to content

Commit 2e5ae92

Browse files
author
Tsvetan Raikov
committed
Added: debug --watch should start livesync with watch option
1 parent 4f9408a commit 2e5ae92

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

docs/man_pages/project/testing/debug-android.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Livesync on device, run the app start Chrome DevTools, and attach the debugger |
1414
Livesync on device, run the app and stop at the first code statement | `$ tns debug android --no-rebuild --debug-brk [--device <Device ID>] [--debug-port <port>] [--timeout <timeout>]`
1515
Livesync in the native emulator, run the app and stop at the first code statement | `$ tns debug android --no-rebuild --debug-brk --emulator [<Emulator Options>] [--timeout <timeout>]`
1616
Livesync in Genymotion, run the app and stop at the first code statement | `$ tns debug android --no-rebuild --debug-brk --geny <Geny Name> [--timeout <timeout>]`
17-
Livesync on device/emulator, run the app, start and attach the debugger. Refresh everything automatically upon changes | `$ tns debug android --no-rebuild --watch [--debug-brk]`
17+
Livesync on device/emulator, run the app, start and attach the debugger. Refresh everything automatically upon changes | `$ tns debug android --watch [--debug-brk]`
1818
Retrieve the device port on which you are debugging | `$ tns debug android [--device <Device ID>] --get-port`
1919
Detach the debug tools | `$ tns debug android --stop`
2020

docs/man_pages/project/testing/debug-ios.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Attach the debug tools to a running app in the iOS Simulator | `$ tns debug ios
1111
Livesync on device, run the app, start Safari Web Inspector and attach the debugger | `$ tns debug ios --no-rebuild`
1212
Livesync on device, run the app and stop at the first code statement | `$ tns debug ios --no-rebuild --debug-brk [--device <Device ID>] [--no-client]`
1313
Livesync in the iOS Simulator, run the app and stop at the first code statement | `$ tns debug ios --no-rebuild --debug-brk --emulator [<Emulator Options>] [--no-client]`
14-
Livesync on device/simulator, run the app, start and attach the debugger. Refresh everything automatically upon changes | `$ tns debug ios --no-rebuild --watch [--debug-brk]`
14+
Livesync on device/simulator, run the app, start and attach the debugger. Refresh everything automatically upon changes | `$ tns debug ios -watch [--debug-brk]`
1515

1616
Debugs your project on a connected device or in the iOS Simulator. <% if(isHtml) { %>Any debugging traffic is forwarded on port 8080 from the device to the local machine.<% } %>
1717

lib/commands/debug.ts

+5
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@
1010
protected $options: IOptions) { }
1111

1212
execute(args: string[]): IFuture<void> {
13+
14+
if (this.$options.watch) {
15+
this.$options.rebuild = false;
16+
}
17+
1318
if (!this.$options.rebuild && !this.$options.start) {
1419
this.$config.debugLivesync = true;
1520
let applicationReloadAction = (deviceAppData: Mobile.IDeviceAppData, localToDevicePaths: Mobile.ILocalToDevicePathData[]): IFuture<void> => {

0 commit comments

Comments
 (0)