1
0
Fork 0

Normalise source directory when passing it to globby so that windows file paths are handled correctly.

This commit is contained in:
ephphatha 2021-01-12 21:09:01 +11:00
parent 43cce60d42
commit b500953d9c
2 changed files with 7 additions and 4 deletions

View file

@ -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
})