Change adb path resolution
Summary: Quick drive-by change. `path.resolve` accepts var-args so we don't resolve to the wrong path on non-Unix systems. Reviewed By: mweststrate Differential Revision: D31502481 fbshipit-source-id: a963cd37d13eb8ef68bccf375f3e074fa8961a9e
This commit is contained in:
committed by
Facebook GitHub Bot
parent
92ec974040
commit
26ed0875cb
@@ -31,7 +31,7 @@ export function getAdbClient(config: Config): Promise<Client> {
|
|||||||
manually before requesting a client. */
|
manually before requesting a client. */
|
||||||
async function createClient(config: Config): Promise<Client> {
|
async function createClient(config: Config): Promise<Client> {
|
||||||
const androidHome = config.androidHome;
|
const androidHome = config.androidHome;
|
||||||
const adbPath = path.resolve(androidHome, 'platform-tools/adb');
|
const adbPath = path.resolve(androidHome, 'platform-tools', 'adb');
|
||||||
return reportPlatformFailures<Client>(
|
return reportPlatformFailures<Client>(
|
||||||
execFile(adbPath, ['start-server']).then(() =>
|
execFile(adbPath, ['start-server']).then(() =>
|
||||||
adbkit.createClient(adbConfig()),
|
adbkit.createClient(adbConfig()),
|
||||||
|
|||||||
Reference in New Issue
Block a user