mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-05-21 05:49:16 +08:00
fix(cli): yeoman create failed
This commit is contained in:
parent
bd335b2931
commit
b62b9d0311
@ -24,17 +24,19 @@
|
||||
"author": "chenjiahan",
|
||||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"@types/fs-extra": "^8.0.1",
|
||||
"@types/fs-extra": "^8.1.0",
|
||||
"@types/yeoman-environment": "^2.3.3",
|
||||
"@types/yeoman-generator": "^3.1.4",
|
||||
"release-it": "^12.4.3",
|
||||
"typescript": "^3.7.4"
|
||||
"release-it": "^13.0.0",
|
||||
"typescript": "^3.8.3"
|
||||
},
|
||||
"dependencies": {
|
||||
"chalk": "^3.0.0",
|
||||
"consola": "^2.11.3",
|
||||
"fs-extra": "^8.1.0",
|
||||
"inquirer": "^7.0.3",
|
||||
"yeoman-generator": "^4.4.0"
|
||||
"inquirer": "^7.0.6",
|
||||
"yeoman-environment": "^2.8.0",
|
||||
"yeoman-generator": "^4.6.0"
|
||||
},
|
||||
"release-it": {
|
||||
"git": {
|
||||
|
@ -2,6 +2,7 @@ import chalk from 'chalk';
|
||||
import consola from 'consola';
|
||||
import { join } from 'path';
|
||||
import { CWD, GENERATOR_DIR } from './constant';
|
||||
import Yeoman from 'yeoman-environment';
|
||||
import Generator from 'yeoman-generator';
|
||||
|
||||
const TEMPLATES = join(GENERATOR_DIR, 'templates');
|
||||
@ -23,9 +24,9 @@ export class VanGenerator extends Generator {
|
||||
|
||||
constructor(name: string) {
|
||||
super([], {
|
||||
env: {
|
||||
env: Yeoman.createEnv([], {
|
||||
cwd: join(CWD, name),
|
||||
},
|
||||
}),
|
||||
resolved: GENERATOR_DIR,
|
||||
});
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user