Skip to content

Commit

Permalink
fix: windows explorer path invalid
Browse files Browse the repository at this point in the history
  • Loading branch information
hubcarl committed Oct 10, 2018
1 parent a09a1e2 commit e9809a9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/tool.js
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ exports.deleteFile = filepath => {

/* istanbul ignore next */
exports.open = filepath => {
const folder = filepath;
const folder = path.isAbsolute(filepath) ? filepath : path.resolve(process.cwd(), filepath);
switch (os.platform()) {
case 'win32':
shell.exec(`explorer ${folder}`);
Expand Down

0 comments on commit e9809a9

Please sign in to comment.