Fix template file path in windows

This commit is contained in:
Emanuel Herrera 2016-11-19 20:24:40 -03:00
parent fa68b8b383
commit 9a915ba63e

View File

@ -20,7 +20,12 @@ const r = function () {
if (_.last(args).includes('~')) { if (_.last(args).includes('~')) {
return _.last(args) return _.last(args)
} }
return resolve.apply(null, arguments)
let filepath = resolve.apply(null, arguments)
if (/^win/.test(process.platform)) {
filepath = filepath.replace(/\\/g, '\\\\')
}
return filepath
} }
const defaults = { const defaults = {