mirror of
https://github.com/status-im/react-native.git
synced 2025-01-10 09:35:48 +00:00
d2c569795c
Summary: No code changes, no testing required. alligned -> aligned allignment -> alignment completly -> completely conseptually -> conceptually decendents -> descendants indefinetly -> indefinitely dimention -> dimension doesnt -> doesn't safegaurd -> safeguard intialization -> initialization hierachy -> hierarchy happend -> happened gaurd -> guard programatically -> programmatically initalized -> initialized immidiately -> immediately occured -> occurred unkown -> unknown neccessary -> necessary neccesarily -> necessarily occuring -> occurring comoponent -> component propogate -> propagate recieved -> received referece -> reference perfomance -> performance recieving -> receiving subsquently -> subsequently scoll -> scroll suprisingly -> surprisingly targetting -> targeting tranform -> transform symetrical -> symmetrical wtih -> with Closes https://github.com/facebook/react-native/pull/17578 Differential Revision: D6718791 Pulled By: shergin fbshipit-source-id: 4ab79c1131ec5971d35a0c7199eba7ec0a0918ad
36 lines
908 B
JavaScript
36 lines
908 B
JavaScript
/**
|
|
* Copyright (c) 2015-present, Facebook, Inc.
|
|
* All rights reserved.
|
|
*
|
|
* This source code is licensed under the BSD-style license found in the
|
|
* LICENSE file in the root directory of this source tree. An additional grant
|
|
* of patent rights can be found in the PATENTS file in the same directory.
|
|
*/
|
|
'use strict';
|
|
|
|
const spawn = require('child_process').spawn;
|
|
|
|
module.exports = function makeCommand(command) {
|
|
return (cb) => {
|
|
if (!cb) {
|
|
throw new Error(`You missed a callback function for the ${command} command`);
|
|
}
|
|
|
|
const args = command.split(' ');
|
|
const cmd = args.shift();
|
|
|
|
const commandProcess = spawn(cmd, args, {
|
|
stdio: 'inherit',
|
|
stdin: 'inherit',
|
|
});
|
|
|
|
commandProcess.on('close', function prelink(code) {
|
|
if (code) {
|
|
throw new Error(`Error occurred during executing "${command}" command`);
|
|
}
|
|
|
|
cb();
|
|
});
|
|
};
|
|
};
|