@@ -87,14 +87,14 @@ class AndroidDebugService implements IDebugService {
8787 }
8888
8989 private unixSocketForward ( local : number , remote : string ) : IFuture < void > {
90- return this . device . adb . executeCommand ( [ "forward" , `tcp:${ local . toString ( ) } ` , `localabstract:${ remote } ` ] ) ;
90+ return this . device . adb . executeCommand ( [ "forward" , `tcp:${ local . toString ( ) } ` , `localabstract:${ remote } ` ] ) ;
9191 }
9292
9393 private debugOnDevice ( ) : IFuture < void > {
9494 return ( ( ) => {
9595 let packageFile = "" ;
9696
97- if ( ! this . $options . debugBrk && ! this . $options . start && ! this . $options . getPort && ! this . $options . stop ) {
97+ if ( ! this . $options . debugBrk && ! this . $options . start && ! this . $options . getPort && ! this . $options . stop ) {
9898 this . $logger . warn ( "Neither --debug-brk nor --start option was specified. Defaulting to --debug-brk." ) ;
9999 this . $options . debugBrk = true ;
100100 }
@@ -110,14 +110,14 @@ class AndroidDebugService implements IDebugService {
110110 this . $logger . out ( "Using " , packageFile ) ;
111111 }
112112
113- this . $devicesService . initialize ( { platform : this . platform , deviceId : this . $options . device } ) . wait ( ) ;
113+ this . $devicesService . initialize ( { platform : this . platform , deviceId : this . $options . device } ) . wait ( ) ;
114114 let action = ( device : Mobile . IAndroidDevice ) : IFuture < void > => { return this . debugCore ( device , packageFile , this . $projectData . projectId ) ; } ;
115115 this . $devicesService . execute ( action ) . wait ( ) ;
116116
117117 } ) . future < void > ( ) ( ) ;
118118 }
119119
120- private debugCore ( device : Mobile . IAndroidDevice , packageFile : string , packageName : string ) : IFuture < void > {
120+ private debugCore ( device : Mobile . IAndroidDevice , packageFile : string , packageName : string ) : IFuture < void > {
121121 return ( ( ) => {
122122 this . device = device ;
123123
@@ -144,9 +144,8 @@ class AndroidDebugService implements IDebugService {
144144 return ( ( ) => {
145145 let startDebuggerCommand = [ "am" , "broadcast" , "-a" , '\"${packageName}-debug\"' , "--ez" , "enable" , "true" ] ;
146146 this . device . adb . executeShellCommand ( startDebuggerCommand ) . wait ( ) ;
147-
148- if ( this . $options . client )
149- {
147+
148+ if ( this . $options . client ) {
150149 let port = this . getForwardedLocalDebugPortForPackageName ( deviceId , packageName ) . wait ( ) ;
151150 this . startDebuggerClient ( port ) . wait ( ) ;
152151 this . openDebuggerClient ( AndroidDebugService . DEFAULT_NODE_INSPECTOR_URL + "?port=" + port ) ;
@@ -160,7 +159,7 @@ class AndroidDebugService implements IDebugService {
160159
161160 private startAppWithDebugger ( packageFile : string , packageName : string ) : IFuture < void > {
162161 return ( ( ) => {
163- if ( ! this . $options . emulator ) {
162+ if ( ! this . $options . emulator ) {
164163 this . device . applicationManager . uninstallApplication ( packageName ) . wait ( ) ;
165164 this . device . applicationManager . installApplication ( packageFile ) . wait ( ) ;
166165 }
@@ -170,7 +169,7 @@ class AndroidDebugService implements IDebugService {
170169
171170 public debugStart ( ) : IFuture < void > {
172171 return ( ( ) => {
173- this . $devicesService . initialize ( { platform : this . platform , deviceId : this . $options . device } ) . wait ( ) ;
172+ this . $devicesService . initialize ( { platform : this . platform , deviceId : this . $options . device } ) . wait ( ) ;
174173 let action = ( device : Mobile . IAndroidDevice ) : IFuture < void > => {
175174 this . device = device ;
176175 return this . debugStartCore ( ) ;
@@ -188,8 +187,7 @@ class AndroidDebugService implements IDebugService {
188187 this . device . applicationManager . stopApplication ( packageName ) . wait ( ) ;
189188 this . device . applicationManager . startApplication ( packageName ) . wait ( ) ;
190189
191- if ( this . $options . client )
192- {
190+ if ( this . $options . client ) {
193191 let localDebugPort = this . getForwardedLocalDebugPortForPackageName ( this . device . deviceInfo . identifier , packageName ) . wait ( ) ;
194192 this . startDebuggerClient ( localDebugPort ) . wait ( ) ;
195193 this . openDebuggerClient ( AndroidDebugService . DEFAULT_NODE_INSPECTOR_URL + "?port=" + localDebugPort ) ;
@@ -208,16 +206,16 @@ class AndroidDebugService implements IDebugService {
208206
209207 private openDebuggerClient ( url : string ) : void {
210208 let defaultDebugUI = "chrome" ;
211- if ( this . $hostInfo . isDarwin ) {
209+ if ( this . $hostInfo . isDarwin ) {
212210 defaultDebugUI = "Google Chrome" ;
213211 }
214- if ( this . $hostInfo . isLinux ) {
212+ if ( this . $hostInfo . isLinux ) {
215213 defaultDebugUI = "google-chrome" ;
216214 }
217215
218216 let debugUI = this . $config . ANDROID_DEBUG_UI || defaultDebugUI ;
219217 let child = this . $opener . open ( url , debugUI ) ;
220- if ( ! child ) {
218+ if ( ! child ) {
221219 this . $errors . failWithoutHelp ( `Unable to open ${ debugUI } .` ) ;
222220 }
223221 }
0 commit comments