Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions packages/platform-android/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"dependencies": {
"@react-native-community/cli-tools": "^2.4.1",
"chalk": "^2.4.2",
"execa": "^1.0.0",
"jetifier": "^1.6.2",
"logkitty": "^0.5.0",
"slash": "^2.0.0",
Expand Down
5 changes: 3 additions & 2 deletions packages/platform-android/src/commands/runAndroid/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

import path from 'path';
import execa from 'execa';
import {spawnSync, spawn, execFileSync} from 'child_process';
import chalk from 'chalk';
import fs from 'fs';
Expand Down Expand Up @@ -48,7 +49,7 @@ export type FlagsT = {|
/**
* Starts the app on a connected Android emulator or device.
*/
function runAndroid(argv: Array<string>, config: ConfigT, args: FlagsT) {
async function runAndroid(argv: Array<string>, config: ConfigT, args: FlagsT) {
if (!checkAndroid(args.root)) {
logger.error(
'Android project not found. Are you sure this is a React Native project?',
Expand All @@ -68,7 +69,7 @@ function runAndroid(argv: Array<string>, config: ConfigT, args: FlagsT) {
);

try {
execFileSync(require.resolve('jetifier/bin/jetify'), {stdio: 'inherit'});
await execa(require.resolve('jetifier/bin/jetify'), {stdio: 'inherit'});
} catch (error) {
throw new CLIError('Failed to run jetifier.', error);
}
Expand Down