Skip to content

Commit cd312e7

Browse files
committed
Better local template handling now handles relative and absolute paths
1 parent 0a33f99 commit cd312e7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/vue-init

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ process.on('exit', function () {
6464
var template = program.args[0]
6565
var hasSlash = template.indexOf('/') > -1
6666
var rawName = program.args[1]
67-
var templatePath = path.normalize(path.join(process.cwd(), template))
67+
var templatePath = exists(template) ? template : path.normalize(path.join(process.cwd(), template))
6868
var inPlace = !rawName || rawName === '.'
6969
var name = inPlace ? path.relative('../', process.cwd()) : rawName
7070
var to = path.resolve(rawName || '.')

0 commit comments

Comments
 (0)