vona-cli 1.0.424 → 1.0.427

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 (2) hide show
  1. package/dist/bin/vona.js +4 -11
  2. package/package.json +3 -3
package/dist/bin/vona.js CHANGED
@@ -1,9 +1,8 @@
1
1
  #!/usr/bin/env node
2
- import path from 'node:path';
3
2
  import { ProcessHelper } from '@cabloy/process-helper';
4
- import fse from 'fs-extra';
5
3
  import semver from 'semver';
6
4
  import { playAttach } from "../play.js";
5
+ import { VonaCommand } from "../start.js";
7
6
  const pnpm_version = '10.19.0';
8
7
  const processHelper = new ProcessHelper(process.cwd());
9
8
  main();
@@ -24,11 +23,6 @@ async function checkPnpm() {
24
23
  }
25
24
  }
26
25
  async function main() {
27
- // bootstrapFile
28
- let bootstrapFile = path.join(import.meta.dirname, '../bootstrap.ts');
29
- if (!fse.existsSync(bootstrapFile)) {
30
- bootstrapFile = path.join(import.meta.dirname, '../bootstrap.js');
31
- }
32
26
  // args
33
27
  let args = [];
34
28
  const rawArgv = process.argv.slice(2);
@@ -36,13 +30,12 @@ async function main() {
36
30
  const isPlayAttach = isPlay && (rawArgv.includes('-a') || rawArgv.includes('--attach'));
37
31
  if (isPlay) {
38
32
  if (!isPlayAttach) {
39
- args = args.concat([bootstrapFile, ':bin:play']);
33
+ args = args.concat([':bin:play']);
40
34
  }
41
35
  args = args.concat(rawArgv.slice(1)).concat(['--dummy']);
42
36
  }
43
37
  else {
44
- args.push(bootstrapFile);
45
- args = args.concat(rawArgv);
38
+ args = rawArgv;
46
39
  }
47
40
  // run
48
41
  if (isPlayAttach) {
@@ -52,6 +45,6 @@ async function main() {
52
45
  if (!isPlay) {
53
46
  await checkPnpm();
54
47
  }
55
- processHelper.spawnCmd({ cmd: 'tsx', args });
48
+ new VonaCommand(args).start();
56
49
  }
57
50
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "vona-cli",
3
3
  "type": "module",
4
- "version": "1.0.424",
4
+ "version": "1.0.427",
5
5
  "description": "vona cli",
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -29,11 +29,11 @@
29
29
  "dist"
30
30
  ],
31
31
  "dependencies": {
32
- "@cabloy/cli": "^3.0.73",
32
+ "@cabloy/cli": "^3.0.74",
33
33
  "@cabloy/process-helper": "^2.0.24",
34
34
  "fs-extra": "^11.2.0",
35
35
  "semver": "^7.6.2",
36
- "vona-cli-set-api": "^1.0.421"
36
+ "vona-cli-set-api": "^1.0.424"
37
37
  },
38
38
  "gitHead": "0eab9dc4a5622caffe89e7b1b3f02c08ccbc4c4b",
39
39
  "scripts": {