Remove path-is-absolute in favor of builtin path.isAbsolute (#5179)

This commit is contained in:
Andres Suarez
2017-01-21 08:33:34 -05:00
committed by Henry Zhu
parent 090f7abda4
commit e9d87ed55c
4 changed files with 2 additions and 6 deletions

View File

@@ -26,7 +26,6 @@
"glob": "^7.0.0",
"lodash": "^4.2.0",
"output-file-sync": "^1.1.0",
"path-is-absolute": "^1.0.0",
"slash": "^1.0.0",
"source-map": "^0.5.0",
"v8flags": "^2.0.10"

View File

@@ -1,4 +1,3 @@
import pathIsAbsolute from "path-is-absolute";
import commander from "commander";
import Module from "module";
import { inspect } from "util";
@@ -123,7 +122,7 @@ if (program.eval || program.print) {
// make the filename absolute
const filename = args[0];
if (!pathIsAbsolute(filename)) args[0] = path.join(process.cwd(), filename);
if (!path.isAbsolute(filename)) args[0] = path.join(process.cwd(), filename);
// add back on node and concat the sliced args
process.argv = ["node"].concat(args);