From 5137e16485b32645c35932fb14d46458da155a84 Mon Sep 17 00:00:00 2001 From: IgorKlopov Date: Tue, 25 Nov 2014 13:46:09 -0800 Subject: [PATCH] WINDOWS_NODE_PATHs are to stay WINDOWS_NODE_PATHs are checked first, and then os.environ['PATH'] --- script/compile-coffee.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/script/compile-coffee.py b/script/compile-coffee.py index ed0156fa6cce..8d02bf9693c2 100755 --- a/script/compile-coffee.py +++ b/script/compile-coffee.py @@ -6,7 +6,10 @@ import sys SOURCE_ROOT = os.path.dirname(os.path.dirname(__file__)) - +WINDOWS_NODE_PATHs = [ + 'C:/Program Files/nodejs', + 'C:/Program Files (x86)/nodejs', +] def main(): input_file = sys.argv[1] @@ -26,7 +29,7 @@ def main(): def find_node(): - PATHs = os.environ['PATH'].split(os.pathsep) + PATHs = WINDOWS_NODE_PATHs + os.environ['PATH'].split(os.pathsep) for path in PATHs: full_path = os.path.join(path, 'node.exe') if os.path.exists(full_path):