juisy 2.0.0-beta.14 → 2.0.0-beta.16
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/dist/cli/CLIFactory.d.ts +2 -0
- package/dist/cli/Command.d.ts +46 -6
- package/dist/cli/GlobalSettings.schema.json +1 -1
- package/dist/cli/InterfaceUtils.d.ts +17 -13
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +503 -454
- package/dist/cli/plugins/register-bump-version-command/cmds/index.d.ts +14 -2
- package/dist/cli/plugins/register-release-command/augment.d.ts +2 -2
- package/dist/cli/types.d.ts +6 -2
- package/dist/cli/utils.d.ts +1 -10
- package/dist/eject.d.ts +2 -0
- package/dist/index.js +7 -2
- package/dist/templater/index.js +1 -1
- package/dist/vite/plugins/inject-css-variables/index.js +1 -1
- package/dist/vite/plugins/inject-project-globals/index.js +1 -1
- package/package.json +202 -194
- package/dist/cli/plugins/command-handler-injections/augment.d.ts +0 -29
- package/dist/cli/plugins/command-handler-injections/command-visitors/command-handler-injections.d.ts +0 -10
- package/dist/cli/plugins/command-handler-injections/index.d.ts +0 -3
|
@@ -1,3 +1,15 @@
|
|
|
1
1
|
import { Command } from '../../../Command';
|
|
2
|
-
|
|
3
|
-
export default
|
|
2
|
+
import { CLIEngine, CommandHandlerArgs } from '../../../types';
|
|
3
|
+
export default class BumpVersionCommand extends Command {
|
|
4
|
+
command: string;
|
|
5
|
+
describe: string;
|
|
6
|
+
meta: {
|
|
7
|
+
private: boolean;
|
|
8
|
+
};
|
|
9
|
+
builder(cli: CLIEngine): CLIEngine;
|
|
10
|
+
handler(argv: CommandHandlerArgs<{
|
|
11
|
+
preid: string;
|
|
12
|
+
file: string;
|
|
13
|
+
indent: number;
|
|
14
|
+
}>): Promise<void>;
|
|
15
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Config as ReleaseItConfig } from 'release-it';
|
|
2
2
|
declare module '../../types' {
|
|
3
3
|
interface GlobalSettings {
|
|
4
4
|
/**
|
|
5
5
|
* Release configuration
|
|
6
6
|
*/
|
|
7
|
-
release?: UserProvidedConfigSetting<
|
|
7
|
+
release?: UserProvidedConfigSetting<ReleaseItConfig>;
|
|
8
8
|
}
|
|
9
9
|
}
|
package/dist/cli/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Argv, CommandModule as YargsCommandModule, MiddlewareFunction } from 'yargs';
|
|
1
|
+
import { Argv, ArgumentsCamelCase, CommandModule as YargsCommandModule, MiddlewareFunction } from 'yargs';
|
|
2
2
|
import { Command } from './Command';
|
|
3
3
|
/**
|
|
4
4
|
* An object whose all properties have the same type.
|
|
@@ -110,11 +110,15 @@ export interface CommandObject {
|
|
|
110
110
|
/** string used as the description for the command in help text, use `false` for a hidden command */
|
|
111
111
|
describe: YargsCommandModule['describe'];
|
|
112
112
|
/** a function which will be passed the parsed argv. */
|
|
113
|
-
handler:
|
|
113
|
+
handler: YargsCommandModule['handler'];
|
|
114
114
|
/** object declaring the options the command accepts, or a function accepting and returning a yargs instance */
|
|
115
115
|
builder: (cli: CLIEngine) => CLIEngine | PromiseLike<CLIEngine>;
|
|
116
116
|
middlewares?: MiddlewareFunction[];
|
|
117
117
|
}
|
|
118
|
+
/**
|
|
119
|
+
* @group Types
|
|
120
|
+
*/
|
|
121
|
+
export type CommandHandlerArgs<T = {}> = ArgumentsCamelCase<T>;
|
|
118
122
|
/**
|
|
119
123
|
* @group Types
|
|
120
124
|
*/
|
package/dist/cli/utils.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CommandObject, CLIEngine
|
|
1
|
+
import { CommandObject, CLIEngine } from './types';
|
|
2
2
|
/**
|
|
3
3
|
* @ignore
|
|
4
4
|
* @param target - The target builder
|
|
@@ -8,12 +8,3 @@ import { CommandObject, CLIEngine, CommandHandler } from './types';
|
|
|
8
8
|
* that will be called before target. Target can be undefined
|
|
9
9
|
*/
|
|
10
10
|
export declare function wrapCommandBuilder(target: CommandObject['builder'], builder: (cli: CLIEngine) => CLIEngine): (cli: CLIEngine) => CLIEngine | PromiseLike<CLIEngine>;
|
|
11
|
-
/**
|
|
12
|
-
* @ignore
|
|
13
|
-
* @param target - The target handler
|
|
14
|
-
* @param handler - The wrap
|
|
15
|
-
* @description
|
|
16
|
-
* Wrap command handler (target) with handler passed as second parameter
|
|
17
|
-
* that will be called before target. Target can be undefined
|
|
18
|
-
*/
|
|
19
|
-
export declare function wrapCommandhandler(target: CommandHandler, handler: CommandHandler): CommandHandler;
|
package/dist/eject.d.ts
CHANGED
|
@@ -7,6 +7,7 @@ export type EjectOptions = {
|
|
|
7
7
|
targetDir?: string;
|
|
8
8
|
logLevel?: LogLevelDesc;
|
|
9
9
|
ignoreFiles?: string[];
|
|
10
|
+
templateData?: Record<string, any> | ((identifier: string) => Record<string, any> | Promise<Record<string, any>>);
|
|
10
11
|
processor?: (content: string, identifier: string) => string | Promise<string>;
|
|
11
12
|
onError?: (identifier: string, fromPath: string, toPath: string, err: Error) => void | Promise<void>;
|
|
12
13
|
onSuccess?: (identifier: string, fromPath: string, toPath: string) => void | Promise<void>;
|
|
@@ -17,6 +18,7 @@ export type EjectOptions = {
|
|
|
17
18
|
* @param options - The options object
|
|
18
19
|
* @param options.force - If true, the target files will be overwritten
|
|
19
20
|
* @param options.targetDir - The target directory absolute path
|
|
21
|
+
* @param options.templateData - The template data object
|
|
20
22
|
* @param options.processor - The template file content processor function.
|
|
21
23
|
* Takes content as unique argument and must return string or a Promise that resolves a string
|
|
22
24
|
* @param options.onError - The callback if an error occurs
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* juisy v2.0.0-beta.
|
|
2
|
+
* juisy v2.0.0-beta.16
|
|
3
3
|
* Copyright © 2022-Present Hervé Perchec
|
|
4
4
|
*/
|
|
5
5
|
|
|
@@ -123,6 +123,7 @@ async function isFile(filePath) {
|
|
|
123
123
|
async function ejectFile(from, to, identifier = null, options) {
|
|
124
124
|
identifier = identifier || path.basename(from);
|
|
125
125
|
const force = options?.force || false;
|
|
126
|
+
const templateData = options?.templateData;
|
|
126
127
|
const processor = options?.processor || (async (str, _identifier) => str);
|
|
127
128
|
const onError = options?.onError || (async (_identifier, fromPath, toPath, err) => {
|
|
128
129
|
throw err;
|
|
@@ -134,7 +135,7 @@ async function ejectFile(from, to, identifier = null, options) {
|
|
|
134
135
|
const write = await fs.exists(to) ? force : true;
|
|
135
136
|
if (write) {
|
|
136
137
|
const template = await fs.readFile(from, { encoding: "utf8" });
|
|
137
|
-
const content = await templater.render(template);
|
|
138
|
+
const content = await templater.render(template, typeof templateData === "function" ? await templateData(identifier) : templateData);
|
|
138
139
|
const processedContent = await processor(content, identifier);
|
|
139
140
|
await fs.ensureFile(to);
|
|
140
141
|
await fs.writeFile(to, processedContent);
|
|
@@ -160,6 +161,8 @@ async function eject(templateDir, identifier, options) {
|
|
|
160
161
|
if (await isFile(fullPath)) {
|
|
161
162
|
if (!ignoreFiles.includes(identifier)) {
|
|
162
163
|
await ejectFile(fullPath, path.resolve(targetDir, identifier), identifier, {
|
|
164
|
+
force: options?.force,
|
|
165
|
+
templateData: options?.templateData,
|
|
163
166
|
processor: options?.processor,
|
|
164
167
|
onSuccess: options?.onSuccess,
|
|
165
168
|
onError: options?.onError
|
|
@@ -171,6 +174,8 @@ async function eject(templateDir, identifier, options) {
|
|
|
171
174
|
const fullTemplateFilePath = path.resolve(templateDir, fileRelativePath);
|
|
172
175
|
if (!ignoreFiles.includes(fileRelativePath)) {
|
|
173
176
|
await ejectFile(fullTemplateFilePath, path.resolve(targetDir, fileRelativePath), fileRelativePath, {
|
|
177
|
+
force: options?.force,
|
|
178
|
+
templateData: options?.templateData,
|
|
174
179
|
processor: options?.processor,
|
|
175
180
|
onSuccess: options?.onSuccess,
|
|
176
181
|
onError: options?.onError
|
package/dist/templater/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,204 +1,212 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
2
|
+
"name": "juisy",
|
|
3
|
+
"version": "2.0.0-beta.16",
|
|
4
|
+
"description": "Make you JavaScript (and/or TypeScript) project juicy!",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"files": [
|
|
7
|
+
"bin",
|
|
8
|
+
"dist"
|
|
9
|
+
],
|
|
10
|
+
"engines": {
|
|
11
|
+
"node": "^18.0.0 || ^20.0.0 || >=22.0.0"
|
|
12
|
+
},
|
|
13
|
+
"imports": {
|
|
14
|
+
"#juisy": {
|
|
15
|
+
"types": "./dist/index.d.ts",
|
|
16
|
+
"import": "./dist/index.js"
|
|
12
17
|
},
|
|
13
|
-
"
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
"import": "./dist/index.js"
|
|
17
|
-
},
|
|
18
|
-
"#juisy/cli": {
|
|
19
|
-
"types": "./dist/cli/index.d.ts",
|
|
20
|
-
"import": "./dist/cli/index.js"
|
|
21
|
-
},
|
|
22
|
-
"#juisy/templater": {
|
|
23
|
-
"types": "./dist/templater/index.d.ts",
|
|
24
|
-
"import": "./dist/templater/index.js"
|
|
25
|
-
}
|
|
18
|
+
"#juisy/cli": {
|
|
19
|
+
"types": "./dist/cli/index.d.ts",
|
|
20
|
+
"import": "./dist/cli/index.js"
|
|
26
21
|
},
|
|
27
|
-
"
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
"./templater": {
|
|
37
|
-
"types": "./dist/templater/index.d.ts",
|
|
38
|
-
"import": "./dist/templater/index.js"
|
|
39
|
-
},
|
|
40
|
-
"./vite-plugin-inject-css-variables": {
|
|
41
|
-
"types": "./dist/vite/plugins/inject-css-variables/index.d.ts",
|
|
42
|
-
"import": "./dist/vite/plugins/inject-css-variables/index.js"
|
|
43
|
-
},
|
|
44
|
-
"./vite-plugin-inject-project-globals": {
|
|
45
|
-
"types": "./dist/vite/plugins/inject-project-globals/index.d.ts",
|
|
46
|
-
"import": "./dist/vite/plugins/inject-project-globals/index.js"
|
|
47
|
-
}
|
|
48
|
-
},
|
|
49
|
-
"publishConfig": {
|
|
50
|
-
"access": "public"
|
|
51
|
-
},
|
|
52
|
-
"scripts": {
|
|
53
|
-
"build": "vite build",
|
|
54
|
-
"audit": "ncu && npm audit",
|
|
55
|
-
"audit:fix": "ncu --interactive",
|
|
56
|
-
"docs": "npm run docs:cli && npm run docs:api",
|
|
57
|
-
"docs:api": "node ./bin/cli docs generate:api",
|
|
58
|
-
"docs:cli": "npm run docs:cli:private && npm run docs:cli:public",
|
|
59
|
-
"docs:cli:private": "node ./bin/cli docs generate:cli -c ./docs/cli/private/config.js",
|
|
60
|
-
"docs:cli:public": "node ./bin/cli docs generate:cli -c ./docs/cli/public/config.js",
|
|
61
|
-
"example:reset": "git checkout --no-overlay -- example && cd example && git clean -fdX",
|
|
62
|
-
"example:test": "npm run example:reset && cd example && npm install -D juisy@file:../ && npx juisy squeeze && npm run docs:readme",
|
|
63
|
-
"print:globals": "node --no-warnings ./bin/cli print:globals",
|
|
64
|
-
"release": "release-it --no-increment",
|
|
65
|
-
"test": "node ./bin/cli test",
|
|
66
|
-
"test:dev": "npm test -- --watch",
|
|
67
|
-
"test:ui": "npm test -- --ui"
|
|
68
|
-
},
|
|
69
|
-
"repository": {
|
|
70
|
-
"type": "git",
|
|
71
|
-
"url": "git+https://gitlab.com/hperchec/juisy.git"
|
|
72
|
-
},
|
|
73
|
-
"keywords": [
|
|
74
|
-
"js",
|
|
75
|
-
"build",
|
|
76
|
-
"release",
|
|
77
|
-
"changelog",
|
|
78
|
-
"bin",
|
|
79
|
-
"cmd",
|
|
80
|
-
"easy"
|
|
81
|
-
],
|
|
82
|
-
"author": {
|
|
83
|
-
"name": "Hervé Perchec",
|
|
84
|
-
"email": "contact@herve-perchec.com",
|
|
85
|
-
"url": "https://gitlab.com/herveperchec"
|
|
86
|
-
},
|
|
87
|
-
"license": "GPL-3.0-only",
|
|
88
|
-
"bugs": {
|
|
89
|
-
"url": "https://gitlab.com/hperchec/juisy/issues"
|
|
90
|
-
},
|
|
91
|
-
"homepage": "https://hperchec.gitlab.io/juisy",
|
|
92
|
-
"bin": {
|
|
93
|
-
"juisy": "./bin/cli/index.js"
|
|
22
|
+
"#juisy/templater": {
|
|
23
|
+
"types": "./dist/templater/index.d.ts",
|
|
24
|
+
"import": "./dist/templater/index.js"
|
|
25
|
+
}
|
|
26
|
+
},
|
|
27
|
+
"exports": {
|
|
28
|
+
".": {
|
|
29
|
+
"types": "./dist/index.d.ts",
|
|
30
|
+
"import": "./dist/index.js"
|
|
94
31
|
},
|
|
95
|
-
"
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
"@github/markdownlint-github": "^0.6.3",
|
|
99
|
-
"@release-it/bumper": "6.0.1",
|
|
100
|
-
"@release-it/conventional-changelog": "^9.0.4",
|
|
101
|
-
"@stylistic/eslint-plugin": "^2",
|
|
102
|
-
"@typescript-eslint/eslint-plugin": "^8",
|
|
103
|
-
"chalk": "^5.4.1",
|
|
104
|
-
"conventional-changelog-cli": "^5.0.0",
|
|
105
|
-
"eslint": "^9",
|
|
106
|
-
"lint-staged": "^14.0.1",
|
|
107
|
-
"markdownlint-cli2": "^0.12.0",
|
|
108
|
-
"markdownlint-cli2-formatter-pretty": "^0.0.7",
|
|
109
|
-
"prompts": "^2.4.2",
|
|
110
|
-
"release-it": "^17.11.0",
|
|
111
|
-
"simple-git-hooks": "^2.9.0",
|
|
112
|
-
"yargs": "^17.7.2"
|
|
32
|
+
"./cli": {
|
|
33
|
+
"types": "./dist/cli/index.d.ts",
|
|
34
|
+
"import": "./dist/cli/index.js"
|
|
113
35
|
},
|
|
114
|
-
"
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
},
|
|
118
|
-
"@release-it/conventional-changelog": {
|
|
119
|
-
"optional": true
|
|
120
|
-
}
|
|
36
|
+
"./templater": {
|
|
37
|
+
"types": "./dist/templater/index.d.ts",
|
|
38
|
+
"import": "./dist/templater/index.js"
|
|
121
39
|
},
|
|
122
|
-
"
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
"@rollup/plugin-typescript": "^12.1.2",
|
|
126
|
-
"@stylistic/eslint-plugin": "^2.12.1",
|
|
127
|
-
"@types/conventional-changelog": "^3.1.5",
|
|
128
|
-
"@types/conventional-changelog-config-spec": "^2.1.5",
|
|
129
|
-
"@types/ejs": "^3.1.5",
|
|
130
|
-
"@types/fs-extra": "^11.0.4",
|
|
131
|
-
"@types/lint-staged": "^13.3.0",
|
|
132
|
-
"@types/lodash.get": "^4.4.9",
|
|
133
|
-
"@types/lodash.kebabcase": "^4.1.9",
|
|
134
|
-
"@types/lodash.merge": "^4.6.9",
|
|
135
|
-
"@types/lodash.set": "^4.3.9",
|
|
136
|
-
"@types/node": "^22.10.2",
|
|
137
|
-
"@types/prompts": "^2.4.9",
|
|
138
|
-
"@types/semver": "^7.5.8",
|
|
139
|
-
"@types/yargs": "^17.0.33",
|
|
140
|
-
"@types/yargs-parser": "^21.0.3",
|
|
141
|
-
"@typescript-eslint/eslint-plugin": "^8.18.1",
|
|
142
|
-
"@vitest/coverage-v8": "^2.1.8",
|
|
143
|
-
"@vitest/ui": "^2.1.8",
|
|
144
|
-
"cpy-cli": "^5.0.0",
|
|
145
|
-
"eslint": "^9.17.0",
|
|
146
|
-
"happy-dom": "^15.11.7",
|
|
147
|
-
"json-schema-to-ts": "^3.1.1",
|
|
148
|
-
"lint-staged": "^14.0.1",
|
|
149
|
-
"npm-check-updates": "^17.1.12",
|
|
150
|
-
"quicktype": "^23.0.170",
|
|
151
|
-
"typedoc": "^0.28.1",
|
|
152
|
-
"typedoc-plugin-frontmatter": "^1.3.0",
|
|
153
|
-
"typedoc-plugin-markdown": "^4.5.2",
|
|
154
|
-
"typedoc-vitepress-theme": "^1.1.2",
|
|
155
|
-
"typescript": "^5.7.2",
|
|
156
|
-
"vite": "^5.4.11",
|
|
157
|
-
"vite-plugin-dts": "^4.3.0",
|
|
158
|
-
"vite-plugin-generate-file": "^0.2.0",
|
|
159
|
-
"vitest": "^2.1.8"
|
|
40
|
+
"./vite-plugin-inject-css-variables": {
|
|
41
|
+
"types": "./dist/vite/plugins/inject-css-variables/index.d.ts",
|
|
42
|
+
"import": "./dist/vite/plugins/inject-css-variables/index.js"
|
|
160
43
|
},
|
|
161
|
-
"
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
44
|
+
"./vite-plugin-inject-project-globals": {
|
|
45
|
+
"types": "./dist/vite/plugins/inject-project-globals/index.d.ts",
|
|
46
|
+
"import": "./dist/vite/plugins/inject-project-globals/index.js"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"publishConfig": {
|
|
50
|
+
"access": "public"
|
|
51
|
+
},
|
|
52
|
+
"scripts": {
|
|
53
|
+
"build": "vite build",
|
|
54
|
+
"audit": "ncu && npm audit",
|
|
55
|
+
"audit:fix": "ncu --interactive",
|
|
56
|
+
"docs": "npm run docs:cli && npm run docs:api",
|
|
57
|
+
"docs:api": "node ./bin/cli docs generate:api",
|
|
58
|
+
"docs:cli": "npm run docs:cli:private && npm run docs:cli:public",
|
|
59
|
+
"docs:cli:private": "node ./bin/cli docs generate:cli -c ./docs/cli/private/config.js",
|
|
60
|
+
"docs:cli:public": "node ./bin/cli docs generate:cli -c ./docs/cli/public/config.js",
|
|
61
|
+
"example:reset": "git checkout --no-overlay -- example && cd example && git clean -fdX",
|
|
62
|
+
"example:test": "npm run example:reset && cd example && npm install -D juisy@file:../ && npx juisy squeeze && npm run docs:readme",
|
|
63
|
+
"print:globals": "node --no-warnings ./bin/cli print:globals",
|
|
64
|
+
"release": "release-it --no-increment",
|
|
65
|
+
"test": "node ./bin/cli test",
|
|
66
|
+
"test:dev": "npm test -- --watch",
|
|
67
|
+
"test:ui": "vitest --ui"
|
|
68
|
+
},
|
|
69
|
+
"repository": {
|
|
70
|
+
"type": "git",
|
|
71
|
+
"url": "git+https://gitlab.com/hperchec/juisy.git"
|
|
72
|
+
},
|
|
73
|
+
"keywords": [
|
|
74
|
+
"js",
|
|
75
|
+
"build",
|
|
76
|
+
"release",
|
|
77
|
+
"changelog",
|
|
78
|
+
"bin",
|
|
79
|
+
"cmd",
|
|
80
|
+
"easy"
|
|
81
|
+
],
|
|
82
|
+
"author": {
|
|
83
|
+
"name": "Hervé Perchec",
|
|
84
|
+
"email": "contact@herve-perchec.com",
|
|
85
|
+
"url": "https://gitlab.com/herveperchec"
|
|
86
|
+
},
|
|
87
|
+
"license": "GPL-3.0-only",
|
|
88
|
+
"bugs": {
|
|
89
|
+
"url": "https://gitlab.com/hperchec/juisy/issues"
|
|
90
|
+
},
|
|
91
|
+
"homepage": "https://hperchec.gitlab.io/juisy",
|
|
92
|
+
"bin": {
|
|
93
|
+
"juisy": "./bin/cli/index.js"
|
|
94
|
+
},
|
|
95
|
+
"peerDependencies": {
|
|
96
|
+
"@commitlint/cli": "^19.6.1",
|
|
97
|
+
"@commitlint/config-conventional": "^19.6.0",
|
|
98
|
+
"@github/markdownlint-github": "^0.6.3",
|
|
99
|
+
"@release-it/bumper": "6.0.1",
|
|
100
|
+
"@release-it/conventional-changelog": "^9.0.4",
|
|
101
|
+
"@stylistic/eslint-plugin": "^2",
|
|
102
|
+
"@typescript-eslint/eslint-plugin": "^8",
|
|
103
|
+
"chalk": "^5.4.1",
|
|
104
|
+
"conventional-changelog-cli": "^5.0.0",
|
|
105
|
+
"eslint": "^9",
|
|
106
|
+
"globals": "^15",
|
|
107
|
+
"lint-staged": "^14.0.1",
|
|
108
|
+
"markdownlint-cli2": "^0.12.0",
|
|
109
|
+
"markdownlint-cli2-formatter-pretty": "^0.0.7",
|
|
110
|
+
"prompts": "^2.4.2",
|
|
111
|
+
"release-it": "^17.11.0",
|
|
112
|
+
"simple-git-hooks": "^2.9.0",
|
|
113
|
+
"yargs": "^17.7.2"
|
|
114
|
+
},
|
|
115
|
+
"peerDependenciesMeta": {
|
|
116
|
+
"@release-it/bumper": {
|
|
117
|
+
"optional": true
|
|
200
118
|
},
|
|
201
|
-
"release-it": {
|
|
202
|
-
|
|
119
|
+
"@release-it/conventional-changelog": {
|
|
120
|
+
"optional": true
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
"devDependencies": {
|
|
124
|
+
"@babel/eslint-parser": "^7.25.9",
|
|
125
|
+
"@conventional-changelog/git-client": "^1.0.1",
|
|
126
|
+
"@rollup/plugin-typescript": "^12.1.2",
|
|
127
|
+
"@stylistic/eslint-plugin": "^2.12.1",
|
|
128
|
+
"@types/conventional-changelog": "^3.1.5",
|
|
129
|
+
"@types/conventional-changelog-config-spec": "^2.1.5",
|
|
130
|
+
"@types/ejs": "^3.1.5",
|
|
131
|
+
"@types/fs-extra": "^11.0.4",
|
|
132
|
+
"@types/lint-staged": "^13.3.0",
|
|
133
|
+
"@types/lodash.get": "^4.4.9",
|
|
134
|
+
"@types/lodash.kebabcase": "^4.1.9",
|
|
135
|
+
"@types/lodash.merge": "^4.6.9",
|
|
136
|
+
"@types/lodash.set": "^4.3.9",
|
|
137
|
+
"@types/node": "^22.10.2",
|
|
138
|
+
"@types/prompts": "^2.4.9",
|
|
139
|
+
"@types/semver": "^7.5.8",
|
|
140
|
+
"@types/yargs": "^17.0.33",
|
|
141
|
+
"@types/yargs-parser": "^21.0.3",
|
|
142
|
+
"@typescript-eslint/eslint-plugin": "^8.18.1",
|
|
143
|
+
"@vitest/coverage-v8": "^2.1.8",
|
|
144
|
+
"@vitest/ui": "^2.1.8",
|
|
145
|
+
"cpy-cli": "^5.0.0",
|
|
146
|
+
"eslint": "^9.17.0",
|
|
147
|
+
"happy-dom": "^15.11.7",
|
|
148
|
+
"json-schema-to-ts": "^3.1.1",
|
|
149
|
+
"lint-staged": "^14.0.1",
|
|
150
|
+
"npm-check-updates": "^17.1.12",
|
|
151
|
+
"quicktype": "^23.0.170",
|
|
152
|
+
"typedoc": "^0.28.1",
|
|
153
|
+
"typedoc-plugin-frontmatter": "^1.3.0",
|
|
154
|
+
"typedoc-plugin-markdown": "^4.5.2",
|
|
155
|
+
"typedoc-vitepress-theme": "^1.1.2",
|
|
156
|
+
"typescript": "^5.7.2",
|
|
157
|
+
"vite": "^5.4.11",
|
|
158
|
+
"vite-plugin-dts": "^4.3.0",
|
|
159
|
+
"vite-plugin-generate-file": "^0.2.0",
|
|
160
|
+
"vitest": "^2.1.8"
|
|
161
|
+
},
|
|
162
|
+
"dependencies": {
|
|
163
|
+
"@commitlint/types": "^19.8.0",
|
|
164
|
+
"@dotenvx/dotenvx": "^1.31.0",
|
|
165
|
+
"ascii-tree": "^0.3.0",
|
|
166
|
+
"chalk": "^5.4.1",
|
|
167
|
+
"conventional-recommended-bump": "^10.0.0",
|
|
168
|
+
"deepmerge": "^4.3.1",
|
|
169
|
+
"ejs": "^3.1.10",
|
|
170
|
+
"execa": "^9.5.2",
|
|
171
|
+
"find-up": "^7.0.0",
|
|
172
|
+
"fs-extra": "^11.2.0",
|
|
173
|
+
"github-slugger": "^2.0.0",
|
|
174
|
+
"glob": "^11.0.0",
|
|
175
|
+
"handlebars": "^4.7.8",
|
|
176
|
+
"import-single-ts": "^1.2.0",
|
|
177
|
+
"indent-string": "^5.0.0",
|
|
178
|
+
"json-2-csv": "^5.5.7",
|
|
179
|
+
"jstoxml": "^5.0.2",
|
|
180
|
+
"lodash.get": "^4.4.2",
|
|
181
|
+
"lodash.kebabcase": "^4.1.1",
|
|
182
|
+
"lodash.merge": "^4.6.2",
|
|
183
|
+
"lodash.set": "^4.3.2",
|
|
184
|
+
"loglevel": "^1.9.2",
|
|
185
|
+
"markdown-table": "^3.0.4",
|
|
186
|
+
"markdown-toc": "^1.2.0",
|
|
187
|
+
"markdown-utils": "^1.0.0",
|
|
188
|
+
"package-json-type": "^1.0.3",
|
|
189
|
+
"pkg-dir": "^8.0.0",
|
|
190
|
+
"prompts": "^2.4.2",
|
|
191
|
+
"remark": "^15.0.1",
|
|
192
|
+
"remark-frontmatter": "^5.0.0",
|
|
193
|
+
"remark-toc": "^9.0.0",
|
|
194
|
+
"semver": "^7.7.1",
|
|
195
|
+
"simple-git-hooks": "^2.9.0",
|
|
196
|
+
"strip-ansi": "^7.1.0",
|
|
197
|
+
"ts-json-schema-generator": "^2.3.0",
|
|
198
|
+
"yaml": "^2.6.1",
|
|
199
|
+
"yargs": "^17.7.2",
|
|
200
|
+
"yargs-parser": "^21.1.1"
|
|
201
|
+
},
|
|
202
|
+
"release-it": {
|
|
203
|
+
"git": false
|
|
204
|
+
},
|
|
205
|
+
"overrides": {
|
|
206
|
+
"simple-git-hooks": {
|
|
207
|
+
"scripts": {
|
|
208
|
+
"postinstall": ""
|
|
209
|
+
}
|
|
203
210
|
}
|
|
211
|
+
}
|
|
204
212
|
}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { CommandModule as YargsCommandModule, CommandBuilder, MiddlewareFunction } from 'yargs';
|
|
2
|
-
declare module '../../types' {
|
|
3
|
-
/** Shims for private yargs types */
|
|
4
|
-
interface Positional {
|
|
5
|
-
cmd: NotEmptyArray<string>;
|
|
6
|
-
variadic: boolean;
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* An array whose first element is not undefined.
|
|
10
|
-
*/
|
|
11
|
-
type NotEmptyArray<T = any> = [T, ...T[]];
|
|
12
|
-
interface CommandHandlerThisArg {
|
|
13
|
-
builder: CommandBuilder;
|
|
14
|
-
demanded: Positional[];
|
|
15
|
-
deprecated?: boolean;
|
|
16
|
-
description?: string | false;
|
|
17
|
-
handler: CommandObject['handler'];
|
|
18
|
-
middlewares: MiddlewareFunction[];
|
|
19
|
-
optional: Positional[];
|
|
20
|
-
original: string;
|
|
21
|
-
engine: CLIEngine;
|
|
22
|
-
log: (msg?: string, options?: any) => void;
|
|
23
|
-
}
|
|
24
|
-
/**
|
|
25
|
-
* Type declaration to extend "this" type inside command handler method
|
|
26
|
-
* @group Types
|
|
27
|
-
*/
|
|
28
|
-
type CommandHandler = (this: CommandHandlerThisArg, argv: Parameters<YargsCommandModule['handler']>[0]) => ReturnType<YargsCommandModule['handler']>;
|
|
29
|
-
}
|
package/dist/cli/plugins/command-handler-injections/command-visitors/command-handler-injections.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { CommandVisitor } from '../../../types';
|
|
2
|
-
/**
|
|
3
|
-
* Global command visitor to auto-set command meta
|
|
4
|
-
* @ignore
|
|
5
|
-
* @param commandObject - The command object
|
|
6
|
-
* @param cli - The CLIEngine instance
|
|
7
|
-
* @returns The commandObject with wrapped handler to inject properties.
|
|
8
|
-
*/
|
|
9
|
-
export declare const visitor: CommandVisitor;
|
|
10
|
-
export declare const options: {};
|