mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Update getCommands.js
Summary: Fixes issue with path for Windows. cc grabbou Closes https://github.com/facebook/react-native/pull/9898 Differential Revision: D3864923 fbshipit-source-id: e785bfe0f01f9cf0c1964518fed03e2090300a31
This commit is contained in:
committed by
Konstantin Raev
parent
85c3cffd48
commit
e6c26b71ed
@@ -13,7 +13,7 @@ module.exports = function getCommands() {
|
||||
const appRoot = process.cwd();
|
||||
const plugins = findPlugins([appRoot])
|
||||
.map(pathToCommands => {
|
||||
const name = pathToCommands.split('/')[0];
|
||||
const name = pathToCommands.split(path.sep)[0];
|
||||
|
||||
return attachPackage(
|
||||
require(path.join(appRoot, 'node_modules', pathToCommands)),
|
||||
|
||||
Reference in New Issue
Block a user