Skip to content

Commit

Permalink
Use 'slash' on input files before globbing to support absolute paths …
Browse files Browse the repository at this point in the history
…with backslashes on Windows (#355)
  • Loading branch information
matthias-christen committed Oct 20, 2020
1 parent c94c188 commit c634575
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion index.js
Expand Up @@ -8,6 +8,7 @@ const stdin = require('get-stdin')
const read = require('read-cache')
const chalk = require('chalk')
const globber = require('globby')
const slash = require('slash')
const chokidar = require('chokidar')

const postcss = require('postcss')
Expand Down Expand Up @@ -57,7 +58,7 @@ Promise.resolve()
}

if (input && input.length) {
return globber(input, { dot: argv.includeDotfiles })
return globber(input.map(slash), { dot: argv.includeDotfiles })
}

if (argv.replace || argv.dir) {
Expand Down
1 change: 1 addition & 0 deletions package.json
Expand Up @@ -28,6 +28,7 @@
"postcss-reporter": "^7.0.0",
"pretty-hrtime": "^1.0.3",
"read-cache": "^1.0.0",
"slash": "^3.0.0",
"yargs": "^16.0.0"
},
"devDependencies": {
Expand Down

0 comments on commit c634575

Please sign in to comment.