From 9bdc4289385ddd779dc199713bf9c389e8c94029 Mon Sep 17 00:00:00 2001 From: Chris Drackett Date: Wed, 1 Mar 2017 17:56:51 -0800 Subject: [PATCH] fixing things for people with the username `cwd` closes #1694 --- packages/react-dev-utils/getProcessForPort.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react-dev-utils/getProcessForPort.js b/packages/react-dev-utils/getProcessForPort.js index 5540fbad47a..70f89195f39 100644 --- a/packages/react-dev-utils/getProcessForPort.js +++ b/packages/react-dev-utils/getProcessForPort.js @@ -43,7 +43,7 @@ function getProcessCommand(processId, processDirectory) { } function getDirectoryOfProcessById(processId) { - return execSync('lsof -p '+ processId + ' | grep cwd | awk \'{print $9}\'', execOptions).trim(); + return execSync('lsof -p '+ processId + ' | awk '$4=="cwd"' | awk \'{print $9}\'', execOptions).trim(); } function getProcessForPort(port) {