summaryrefslogtreecommitdiff
path: root/tools/run_node.py
diff options
context:
space:
mode:
authorJaePil Jung <jjp5023@gmail.com>2019-01-25 00:54:43 +0900
committerRyan Dahl <ry@tinyclouds.org>2019-01-24 10:54:43 -0500
commit7f88b5fff3fe8aed2073d4347d3ab847fc4c528a (patch)
tree5391a4d6ca9ec2add34719baeaf4dbd884c79b07 /tools/run_node.py
parent2547f0296fc77357b9c11f3bdc7414a68243e775 (diff)
Minor code cleanups (#1570)
Diffstat (limited to 'tools/run_node.py')
-rwxr-xr-xtools/run_node.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/run_node.py b/tools/run_node.py
index 4023f7586..f1221bcd4 100755
--- a/tools/run_node.py
+++ b/tools/run_node.py
@@ -8,13 +8,12 @@ Before running node, we symlink js/node_modules to out/Debug/node_modules.
import subprocess
import sys
import os
-import util
+from util import remove_and_symlink, root_path, run
-root_path = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
tools_path = os.path.join(root_path, "tools")
third_party_path = os.path.join(root_path, "third_party")
target_abs = os.path.join(third_party_path, "node_modules")
target_rel = os.path.relpath(target_abs)
-util.remove_and_symlink(target_rel, "node_modules", True)
-util.run(["node"] + sys.argv[1:], quiet=True)
+remove_and_symlink(target_rel, "node_modules", True)
+run(["node"] + sys.argv[1:], quiet=True)