create-unibest 3.0.5 → 3.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +10 -1
  2. package/dist/index.js +17 -1
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -15,6 +15,15 @@
15
15
 
16
16
  ## 🚤 快速使用
17
17
 
18
+ - 全局安装
19
+
20
+ ```shell
21
+ pnpm install -g create-unibest
22
+ best new my-project
23
+ ```
24
+
25
+ - 临时使用
26
+
18
27
  ```shell
19
- pnpm create unibest@latest
28
+ pnpm create unibest@latest new my-project
20
29
  ```
package/dist/index.js CHANGED
@@ -611,7 +611,7 @@ async function generateProject(options) {
611
611
  }
612
612
 
613
613
  // package.json
614
- var version = "3.0.5";
614
+ var version = "3.0.6";
615
615
 
616
616
  // src/commands/create.ts
617
617
  import { intro, log } from "@clack/prompts";
@@ -679,6 +679,20 @@ var color = {
679
679
  yellow: yellow4
680
680
  };
681
681
 
682
+ // src/utils/help.ts
683
+ function printHelp() {
684
+ console.log(color.green("\ncreate-unibest - \u8DE8\u5E73\u53F0\u5F00\u53D1\u6846\u67B6\u811A\u624B\u67B6"));
685
+ console.log("");
686
+ console.log(color.blue("\u5168\u5C40\u5B89\u88C5:"));
687
+ console.log(" npm install -g create-unibest");
688
+ console.log(" best new my-project");
689
+ console.log(" best create my-project (new \u540C create)");
690
+ console.log("");
691
+ console.log(color.blue("\u4E34\u65F6\u4F7F\u7528:"));
692
+ console.log(" pnpm create unibest@latest new my-project");
693
+ console.log("");
694
+ }
695
+
682
696
  // src/index.ts
683
697
  import { green as green5 } from "kolorist";
684
698
  import { yellow as yellow5 } from "kolorist";
@@ -698,6 +712,7 @@ function main() {
698
712
  break;
699
713
  case "-h":
700
714
  case "--help":
715
+ printHelp();
701
716
  break;
702
717
  case "-v":
703
718
  case "--version":
@@ -707,6 +722,7 @@ function main() {
707
722
  if (command) {
708
723
  console.log(color.red(`\u672A\u77E5\u547D\u4EE4: ${command}`));
709
724
  }
725
+ printHelp();
710
726
  break;
711
727
  }
712
728
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "create-unibest",
3
3
  "type": "module",
4
- "version": "3.0.5",
4
+ "version": "3.0.6",
5
5
  "description": "快速创建unibest项目的脚手架工具",
6
6
  "author": "",
7
7
  "license": "ISC",