@vlandoss/starter 0.1.3 → 0.1.5-git-b33212e.0
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.
- package/bin.mjs +1 -7
- package/dist/{main.mjs → run.mjs} +8 -9
- package/package.json +3 -3
- package/src/run.ts +11 -0
- package/src/main.ts +0 -10
package/bin.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import path, { join } from "node:path";
|
|
2
|
+
import { createPkgService, createShellService, cwd, dirnameOf, getVersion, palette, run } from "@vlandoss/clibuddy";
|
|
2
3
|
import { Argument, Command, Option, createCommand } from "commander";
|
|
3
4
|
import fs from "node:fs";
|
|
4
|
-
import { join } from "node:path";
|
|
5
5
|
import { createLoggy } from "@vlandoss/loggy";
|
|
6
6
|
import nodePlop from "node-plop";
|
|
7
7
|
//#region src/services/config.ts
|
|
@@ -179,11 +179,10 @@ async function createProgram(options) {
|
|
|
179
179
|
return new Command("vland").version(getVersion(ctx.binPkg), "-v, --version").addHelpText("before", BANNER_TEXT).addCommand(createInitCommand(ctx)).addCommand(createAddCommand(ctx));
|
|
180
180
|
}
|
|
181
181
|
//#endregion
|
|
182
|
-
//#region src/
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
}
|
|
182
|
+
//#region src/run.ts
|
|
183
|
+
const BIN_DIR = path.dirname(dirnameOf(import.meta));
|
|
184
|
+
await run(async () => {
|
|
185
|
+
await (await createProgram({ binDir: BIN_DIR })).parseAsync();
|
|
186
|
+
}, logger);
|
|
188
187
|
//#endregion
|
|
189
|
-
export {
|
|
188
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vlandoss/starter",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.5-git-b33212e.0",
|
|
4
4
|
"description": "The CLI to init a new project in Variable Land",
|
|
5
5
|
"homepage": "https://github.com/variableland/dx/tree/main/packages/starter#readme",
|
|
6
6
|
"bugs": {
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"commander": "14.0.3",
|
|
35
35
|
"node-plop": "0.32.3",
|
|
36
|
-
"@vlandoss/clibuddy": "0.1.
|
|
37
|
-
"@vlandoss/loggy": "0.1.
|
|
36
|
+
"@vlandoss/clibuddy": "0.2.1-git-b33212e.0",
|
|
37
|
+
"@vlandoss/loggy": "0.1.2-git-b33212e.0"
|
|
38
38
|
},
|
|
39
39
|
"publishConfig": {
|
|
40
40
|
"access": "public"
|
package/src/run.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import path from "node:path";
|
|
2
|
+
import { dirnameOf, run } from "@vlandoss/clibuddy";
|
|
3
|
+
import { createProgram } from "./program/index.ts";
|
|
4
|
+
import { logger } from "./services/logger.ts";
|
|
5
|
+
|
|
6
|
+
const BIN_DIR = path.dirname(dirnameOf(import.meta));
|
|
7
|
+
|
|
8
|
+
await run(async () => {
|
|
9
|
+
const program = await createProgram({ binDir: BIN_DIR });
|
|
10
|
+
await program.parseAsync();
|
|
11
|
+
}, logger);
|
package/src/main.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { run } from "@vlandoss/clibuddy";
|
|
2
|
-
import { createProgram, type Options } from "./program/index.ts";
|
|
3
|
-
import { logger } from "./services/logger.ts";
|
|
4
|
-
|
|
5
|
-
export async function main(options: Options) {
|
|
6
|
-
await run(async () => {
|
|
7
|
-
const program = await createProgram(options);
|
|
8
|
-
await program.parseAsync();
|
|
9
|
-
}, logger);
|
|
10
|
-
}
|