Normalise source directory when passing it to globby so that windows file paths are handled correctly.
This commit is contained in:
parent
43cce60d42
commit
b500953d9c
2 changed files with 7 additions and 4 deletions
|
@ -4,6 +4,7 @@ const handlebars = require('handlebars')
|
|||
const execa = require('execa')
|
||||
const fs = require('fs')
|
||||
const globby = require('globby')
|
||||
const normalize = require('normalize-path')
|
||||
const mkdirp = require('make-dir')
|
||||
const ora = require('ora')
|
||||
const path = require('path')
|
||||
|
@ -28,7 +29,8 @@ module.exports = async (info) => {
|
|||
template === 'custom'
|
||||
? path.join(process.cwd(), templatePath)
|
||||
: path.join(__dirname, '..', 'template', template)
|
||||
const files = await globby(source, {
|
||||
|
||||
const files = await globby(normalize(source), {
|
||||
dot: true
|
||||
})
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue