Skip to content

Commit

Permalink
Add slash dep to support Windows file paths (#87)
Browse files Browse the repository at this point in the history
Fixes #86
  • Loading branch information
YZirkind authored Apr 8, 2021
1 parent b5ee5a2 commit 90f0551
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ const { argv } = require('yargs')
type: 'boolean',
});
const glob = require('globby').sync;
const slash = require('slash');
const read = require('read-input');
const chalk = require('chalk');
const ejsLint = require('./index.js');
Expand All @@ -30,7 +31,7 @@ const opts = {
preprocessorInclude: argv['preprocessor-include'],
await: argv.await,
};
read(glob(argv._))
read(glob(argv._.map(s => slash(s))))
.then((res) => {
let errored = false;
res.files.forEach((file) => {
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
"ejs-include-regex": "^1.0.0",
"globby": "^11.0.0",
"read-input": "^0.3.1",
"slash": "^3.0.0",
"syntax-error": "^1.1.6",
"yargs": "^16.0.0"
},
Expand Down

0 comments on commit 90f0551

Please sign in to comment.