master
yutent 2023-01-13 11:42:24 +08:00
parent 94dcc67db1
commit b85899650e
3 changed files with 9 additions and 6 deletions

View File

@ -28,7 +28,9 @@ import {
} from './lib/demo-js.js' } from './lib/demo-js.js'
const CURRENT_DIR = process.cwd() const CURRENT_DIR = process.cwd()
const root = dirname(import.meta.url.slice(process.platform === 'win32' ? 10 : 7)) const root = dirname(
import.meta.url.slice(process.platform === 'win32' ? 10 : 7)
)
const { version } = JSON.parse(fs.cat(join(root, './package.json'))) const { version } = JSON.parse(fs.cat(join(root, './package.json')))
const DEFAULT_NAME = 'vue-live-app' const DEFAULT_NAME = 'vue-live-app'
@ -81,7 +83,8 @@ function printHelp() {
{ {
name: 'shouldOverwrite', name: 'shouldOverwrite',
type: _ => (isEmpty(targetDir) ? null : 'toggle'), type: _ => (isEmpty(targetDir) ? null : 'toggle'),
message: _ => `目录 ${cyan(targetDir)} 非空, 是否${red('删除')}目录下所有的文件?`, message: _ =>
`目录 ${cyan(targetDir)} 非空, 是否${red('删除')}目录下所有的文件?`,
initial: false, initial: false,
active: '是', active: '是',
inactive: '否' inactive: '否'

View File

@ -16,11 +16,11 @@ export function writePackageJson(file, name) {
start: 'vue-live dev', start: 'vue-live dev',
build: 'vue-live build' build: 'vue-live build'
}, },
dependencies: { devDependencies: {
'@bytedo/vue-live': '^0.0.11' '@bytedo/vue-live': '^0.0.15'
} }
}, },
' ', 'null,
2 2
), ),
file file

View File

@ -1,7 +1,7 @@
{ {
"name": "create-vue-live", "name": "create-vue-live",
"type": "module", "type": "module",
"version": "0.0.12", "version": "0.0.15",
"bin": { "bin": {
"create-vue-live": "index.js" "create-vue-live": "index.js"
}, },