mirror of
https://github.com/MincoMK/create-computercraft.git
synced 2025-12-10 06:33:18 +00:00
feat: cli args
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "create-computercraft",
|
||||
"version": "1.0.0",
|
||||
"version": "1.0.1",
|
||||
"description": "",
|
||||
"bin": {
|
||||
"create-computercraft": "dist/main.js"
|
||||
|
||||
@@ -15,6 +15,7 @@ async function main() {
|
||||
|
||||
const projectName = await text({
|
||||
message: "What is your project name?",
|
||||
initialValue: process.argv?.[2] ?? undefined,
|
||||
validate(value) {
|
||||
if (!validate(value))
|
||||
return "Project name should satisfy NPM package name rules.";
|
||||
|
||||
Reference in New Issue
Block a user