lism-cli 0.6.0 → 0.8.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/README.md +67 -31
- package/dist/{chunk-G4RBP3W6.js → chunk-RTEZODLP.js} +166 -129
- package/dist/index.js +248 -292
- package/dist/lib.d.ts +70 -93
- package/dist/lib.js +1 -1
- package/package.json +4 -3
- /package/bin/{lism.mjs → lism-cli.mjs} +0 -0
package/dist/lib.d.ts
CHANGED
|
@@ -9,7 +9,7 @@ interface RunCreateArgs {
|
|
|
9
9
|
*/
|
|
10
10
|
lang?: string;
|
|
11
11
|
}
|
|
12
|
-
/** `lism create` / `create-lism` から共通で使える実体関数 */
|
|
12
|
+
/** `lism-cli create` / `create-lism` から共通で使える実体関数 */
|
|
13
13
|
declare function runCreate({ template, targetDir, force, lang }: RunCreateArgs): Promise<void>;
|
|
14
14
|
|
|
15
15
|
/**
|
|
@@ -17,9 +17,10 @@ declare function runCreate({ template, targetDir, force, lang }: RunCreateArgs):
|
|
|
17
17
|
*
|
|
18
18
|
* 命名規則:
|
|
19
19
|
* - `cli.*` … commander の description / argument / option
|
|
20
|
-
* - `create.*` … `lism create` サブコマンド
|
|
21
|
-
* - `
|
|
22
|
-
* - `
|
|
20
|
+
* - `create.*` … `lism-cli create` サブコマンド
|
|
21
|
+
* - `init.*` … `lism-cli init` サブコマンド
|
|
22
|
+
* - `ui.*` … `lism-cli ui` 配下
|
|
23
|
+
* - `skill.*` … `lism-cli skill` 配下
|
|
23
24
|
* - `config.*` … lism.config.* まわりのエラー・警告
|
|
24
25
|
* - `common.*` … 汎用
|
|
25
26
|
*
|
|
@@ -50,29 +51,21 @@ declare const messages: {
|
|
|
50
51
|
readonly ja: "既存ディレクトリを強制上書き";
|
|
51
52
|
readonly en: "Overwrite existing directory";
|
|
52
53
|
};
|
|
53
|
-
readonly 'cli.
|
|
54
|
-
readonly ja: "
|
|
55
|
-
readonly en: "
|
|
56
|
-
};
|
|
57
|
-
readonly 'cli.ui.init.description': {
|
|
58
|
-
readonly ja: "lism.config.js の cli セクションを生成する";
|
|
59
|
-
readonly en: "Generate the cli section of lism.config.js";
|
|
60
|
-
};
|
|
61
|
-
readonly 'cli.ui.init.opt.framework': {
|
|
62
|
-
readonly ja: "フレームワーク";
|
|
63
|
-
readonly en: "Framework";
|
|
54
|
+
readonly 'cli.init.description': {
|
|
55
|
+
readonly ja: "lism.config ファイルを新規生成する";
|
|
56
|
+
readonly en: "Generate a new lism.config file";
|
|
64
57
|
};
|
|
65
|
-
readonly 'cli.
|
|
66
|
-
readonly ja: "
|
|
67
|
-
readonly en: "
|
|
58
|
+
readonly 'cli.init.opt.uiFramework': {
|
|
59
|
+
readonly ja: "UI コンポーネントのフレームワーク(ui.framework)";
|
|
60
|
+
readonly en: "Framework for UI components (ui.framework)";
|
|
68
61
|
};
|
|
69
|
-
readonly 'cli.
|
|
70
|
-
readonly ja: "
|
|
71
|
-
readonly en: "Output directory for
|
|
62
|
+
readonly 'cli.init.opt.uiDir': {
|
|
63
|
+
readonly ja: "UI コンポーネントの出力先ディレクトリ(ui.dir)";
|
|
64
|
+
readonly en: "Output directory for UI components (ui.dir)";
|
|
72
65
|
};
|
|
73
|
-
readonly 'cli.ui.
|
|
74
|
-
readonly ja: "
|
|
75
|
-
readonly en: "
|
|
66
|
+
readonly 'cli.ui.description': {
|
|
67
|
+
readonly ja: "Lism UI コンポーネントの追加・管理";
|
|
68
|
+
readonly en: "Manage Lism UI components";
|
|
76
69
|
};
|
|
77
70
|
readonly 'cli.ui.add.description': {
|
|
78
71
|
readonly ja: "コンポーネントを追加する";
|
|
@@ -106,6 +99,10 @@ declare const messages: {
|
|
|
106
99
|
readonly ja: "スキルを配置する";
|
|
107
100
|
readonly en: "Deploy skills";
|
|
108
101
|
};
|
|
102
|
+
readonly 'cli.skill.add.arg.skill': {
|
|
103
|
+
readonly ja: "配置するスキル名(省略時は全スキル)";
|
|
104
|
+
readonly en: "Skill name to deploy (all skills if omitted)";
|
|
105
|
+
};
|
|
109
106
|
readonly 'cli.skill.add.opt.overwrite': {
|
|
110
107
|
readonly ja: "確認なしで上書き";
|
|
111
108
|
readonly en: "Overwrite without confirmation";
|
|
@@ -215,20 +212,40 @@ declare const messages: {
|
|
|
215
212
|
readonly en: "Failed to rewrite package.json name: {reason}";
|
|
216
213
|
};
|
|
217
214
|
readonly 'create.workspaceReplaced': {
|
|
218
|
-
readonly ja: " package.json の workspace:*
|
|
219
|
-
readonly en: " Replaced workspace:* in package.json with
|
|
215
|
+
readonly ja: " package.json の workspace:* を公開バージョンに置換しました。";
|
|
216
|
+
readonly en: " Replaced workspace:* in package.json with published versions.";
|
|
220
217
|
};
|
|
221
218
|
readonly 'create.workspaceFailed': {
|
|
222
219
|
readonly ja: "package.json の書き換えに失敗しました: {reason}";
|
|
223
220
|
readonly en: "Failed to rewrite package.json: {reason}";
|
|
224
221
|
};
|
|
222
|
+
readonly 'init.alreadyExists': {
|
|
223
|
+
readonly ja: "{filename} は既に存在するため、何も変更しませんでした。";
|
|
224
|
+
readonly en: "{filename} already exists; nothing was changed.";
|
|
225
|
+
};
|
|
226
|
+
readonly 'init.promptUseUi': {
|
|
227
|
+
readonly ja: "Lism UI のコンポーネントも使いますか?(ui セクションを追加します)";
|
|
228
|
+
readonly en: "Will you also use Lism UI components? (adds a ui section)";
|
|
229
|
+
};
|
|
230
|
+
readonly 'init.created': {
|
|
231
|
+
readonly ja: "{path} を作成しました。";
|
|
232
|
+
readonly en: "Created {path}.";
|
|
233
|
+
};
|
|
234
|
+
readonly 'init.uiFrameworkRequired': {
|
|
235
|
+
readonly ja: "非対話環境では --ui-dir 単独で ui セクションを生成できません。--ui-framework を指定してください。";
|
|
236
|
+
readonly en: "Cannot generate the ui section from --ui-dir alone in a non-interactive environment. Specify --ui-framework.";
|
|
237
|
+
};
|
|
238
|
+
readonly 'ui.promptFramework': {
|
|
239
|
+
readonly ja: "フレームワークを選択してください:";
|
|
240
|
+
readonly en: "Select a framework:";
|
|
241
|
+
};
|
|
225
242
|
readonly 'ui.catalogFailed': {
|
|
226
243
|
readonly ja: "カタログの取得に失敗しました{refInfo}: {reason}";
|
|
227
244
|
readonly en: "Failed to fetch catalog{refInfo}: {reason}";
|
|
228
245
|
};
|
|
229
246
|
readonly 'ui.add.noConfig': {
|
|
230
|
-
readonly ja: "
|
|
231
|
-
readonly en: "
|
|
247
|
+
readonly ja: "ui セクションが見つかりません。いくつか質問します。";
|
|
248
|
+
readonly en: "No ui section found. A few questions to get you started.";
|
|
232
249
|
};
|
|
233
250
|
readonly 'ui.add.addingAll': {
|
|
234
251
|
readonly ja: "全 {count} コンポーネントを追加します...";
|
|
@@ -294,45 +311,9 @@ declare const messages: {
|
|
|
294
311
|
readonly ja: " スキップ: {path}";
|
|
295
312
|
readonly en: " Skipped: {path}";
|
|
296
313
|
};
|
|
297
|
-
readonly 'ui.
|
|
298
|
-
readonly ja: "
|
|
299
|
-
readonly en: "
|
|
300
|
-
};
|
|
301
|
-
readonly 'ui.init.promptComponentsDir': {
|
|
302
|
-
readonly ja: "コンポーネントの出力先ディレクトリ:";
|
|
303
|
-
readonly en: "Output directory for components:";
|
|
304
|
-
};
|
|
305
|
-
readonly 'ui.init.promptHelperDir': {
|
|
306
|
-
readonly ja: "helper の出力先ディレクトリ:";
|
|
307
|
-
readonly en: "Output directory for helpers:";
|
|
308
|
-
};
|
|
309
|
-
readonly 'ui.init.patchedUpdate': {
|
|
310
|
-
readonly ja: "{path} に cli セクションを更新しました。";
|
|
311
|
-
readonly en: "Updated the cli section in {path}.";
|
|
312
|
-
};
|
|
313
|
-
readonly 'ui.init.patchedAdd': {
|
|
314
|
-
readonly ja: "{path} に cli セクションを追記しました。";
|
|
315
|
-
readonly en: "Added the cli section to {path}.";
|
|
316
|
-
};
|
|
317
|
-
readonly 'ui.init.notPatched': {
|
|
318
|
-
readonly ja: "{path} に既に cli セクションが含まれているか、export default が検出できませんでした。手動で追記してください。";
|
|
319
|
-
readonly en: "Either {path} already contains a cli section or no export default was detected. Please add it manually.";
|
|
320
|
-
};
|
|
321
|
-
readonly 'ui.init.created': {
|
|
322
|
-
readonly ja: "{path} を作成しました。";
|
|
323
|
-
readonly en: "Created {path}.";
|
|
324
|
-
};
|
|
325
|
-
readonly 'ui.init.legacyDetected': {
|
|
326
|
-
readonly ja: "{filename} を検出しました。lism.config.js へ移行します。古いファイルは後で削除してください。";
|
|
327
|
-
readonly en: "Detected {filename}. Migrating to lism.config.js. Please remove the old file afterwards.";
|
|
328
|
-
};
|
|
329
|
-
readonly 'ui.init.alreadyExists': {
|
|
330
|
-
readonly ja: "{filename} には既に cli セクションが設定されています。上書きするには --force を指定してください。";
|
|
331
|
-
readonly en: "{filename} already has a cli section. Use --force to overwrite.";
|
|
332
|
-
};
|
|
333
|
-
readonly 'ui.init.willOverwrite': {
|
|
334
|
-
readonly ja: "{filename} の既存の cli セクションを上書きします。";
|
|
335
|
-
readonly en: "Overwriting the existing cli section in {filename}.";
|
|
314
|
+
readonly 'ui.add.snippetGuide': {
|
|
315
|
+
readonly ja: "次回から同じ質問をされないために、{filename} の export default オブジェクト内に以下を貼り付けてください:\n\n{snippet}\n";
|
|
316
|
+
readonly en: "To avoid being asked these questions again, paste the following inside the exported config object in {filename}:\n\n{snippet}\n";
|
|
336
317
|
};
|
|
337
318
|
readonly 'ui.list.fetching': {
|
|
338
319
|
readonly ja: "コンポーネント一覧を取得中...";
|
|
@@ -359,8 +340,12 @@ declare const messages: {
|
|
|
359
340
|
readonly en: "No target tools were selected.";
|
|
360
341
|
};
|
|
361
342
|
readonly 'skill.add.fetching': {
|
|
362
|
-
readonly ja: "
|
|
363
|
-
readonly en: "Fetching
|
|
343
|
+
readonly ja: "スキル {skill} を取得中(ref: {ref})...";
|
|
344
|
+
readonly en: "Fetching skill {skill} (ref: {ref})...";
|
|
345
|
+
};
|
|
346
|
+
readonly 'skill.unknownSkill': {
|
|
347
|
+
readonly ja: "スキル \"{name}\" は存在しません。利用可能: {list}";
|
|
348
|
+
readonly en: "Unknown skill \"{name}\". Available: {list}";
|
|
364
349
|
};
|
|
365
350
|
readonly 'skill.add.skippedSame': {
|
|
366
351
|
readonly ja: " スキップ(差分なし): {label}";
|
|
@@ -399,8 +384,8 @@ declare const messages: {
|
|
|
399
384
|
readonly en: "No installed skills found. Run `{invoke} skill add` to deploy them.";
|
|
400
385
|
};
|
|
401
386
|
readonly 'skill.check.fetching': {
|
|
402
|
-
readonly ja: "
|
|
403
|
-
readonly en: "Fetching remote
|
|
387
|
+
readonly ja: "リモートスキル {skill} を取得中(ref: {ref})...";
|
|
388
|
+
readonly en: "Fetching remote skill {skill} (ref: {ref})...";
|
|
404
389
|
};
|
|
405
390
|
readonly 'skill.check.upToDate': {
|
|
406
391
|
readonly ja: " ✓ {label} (最新)";
|
|
@@ -411,8 +396,8 @@ declare const messages: {
|
|
|
411
396
|
readonly en: "All skills are up to date.";
|
|
412
397
|
};
|
|
413
398
|
readonly 'skill.check.outdated': {
|
|
414
|
-
readonly ja: "{count}
|
|
415
|
-
readonly en: "{count}
|
|
399
|
+
readonly ja: "{count} 件の配置に差分があります。`{invoke} skill update` で最新に更新できます。";
|
|
400
|
+
readonly en: "{count} deployment(s) differ from the remote. Run `{invoke} skill update` to update them.";
|
|
416
401
|
};
|
|
417
402
|
readonly 'skill.check.diffModified': {
|
|
418
403
|
readonly ja: "変更 {count}";
|
|
@@ -426,34 +411,26 @@ declare const messages: {
|
|
|
426
411
|
readonly ja: "削除 {count}";
|
|
427
412
|
readonly en: "deleted {count}";
|
|
428
413
|
};
|
|
429
|
-
readonly 'config.legacyWarning': {
|
|
430
|
-
readonly ja: "[deprecated] {filename} は廃止予定です。\"{invoke} ui init\" で lism.config.js へ移行してください。";
|
|
431
|
-
readonly en: "[deprecated] {filename} is deprecated. Run \"{invoke} ui init\" to migrate to lism.config.js.";
|
|
432
|
-
};
|
|
433
|
-
readonly 'config.notFound': {
|
|
434
|
-
readonly ja: "lism.config.js / lism.config.mjs / lism-ui.json のいずれも見つかりません。";
|
|
435
|
-
readonly en: "None of lism.config.js / lism.config.mjs / lism-ui.json were found.";
|
|
436
|
-
};
|
|
437
|
-
readonly 'config.cliSectionMissing': {
|
|
438
|
-
readonly ja: "{filename} から CLI 設定(cli キー)を読み込めませんでした。";
|
|
439
|
-
readonly en: "Failed to read the CLI config (cli key) from {filename}.";
|
|
440
|
-
};
|
|
441
414
|
readonly 'config.invalidFramework': {
|
|
442
|
-
readonly ja: "
|
|
443
|
-
readonly en: "
|
|
415
|
+
readonly ja: "ui.framework は \"react\" または \"astro\" を指定してください。";
|
|
416
|
+
readonly en: "ui.framework must be \"react\" or \"astro\".";
|
|
444
417
|
};
|
|
445
|
-
readonly 'config.
|
|
446
|
-
readonly ja: "
|
|
447
|
-
readonly en: "
|
|
418
|
+
readonly 'config.invalidDir': {
|
|
419
|
+
readonly ja: "ui.dir は文字列で指定してください。";
|
|
420
|
+
readonly en: "ui.dir must be a string.";
|
|
448
421
|
};
|
|
449
|
-
readonly 'config.
|
|
450
|
-
readonly ja: "cli
|
|
451
|
-
readonly en: "cli
|
|
422
|
+
readonly 'config.cliKeyDeprecated': {
|
|
423
|
+
readonly ja: "[deprecated] {filename} の \"cli:\" キーは \"ui:\" への変更が推奨されています。";
|
|
424
|
+
readonly en: "[deprecated] The \"cli:\" key in {filename} is recommended to be renamed to \"ui:\".";
|
|
452
425
|
};
|
|
453
426
|
readonly 'config.loadFailed': {
|
|
454
427
|
readonly ja: "{path} を読み込めませんでした(構文エラー等)。修正してから再実行してください: {reason}";
|
|
455
428
|
readonly en: "Failed to load {path} (syntax error, etc). Please fix it and retry: {reason}";
|
|
456
429
|
};
|
|
430
|
+
readonly 'config.freshConfigExists': {
|
|
431
|
+
readonly ja: "{path} は既に存在するため新規作成できません。";
|
|
432
|
+
readonly en: "Cannot create {path} because it already exists.";
|
|
433
|
+
};
|
|
457
434
|
readonly 'common.done': {
|
|
458
435
|
readonly ja: "完了しました。";
|
|
459
436
|
readonly en: "Done.";
|
package/dist/lib.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lism-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.8.0",
|
|
4
4
|
"description": "CLI for scaffolding projects and adding UI components for Lism CSS / Lism UI.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "ddryo",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
],
|
|
17
17
|
"type": "module",
|
|
18
18
|
"bin": {
|
|
19
|
-
"lism": "./bin/lism.mjs"
|
|
19
|
+
"lism-cli": "./bin/lism-cli.mjs"
|
|
20
20
|
},
|
|
21
21
|
"main": "./dist/lib.js",
|
|
22
22
|
"types": "./dist/lib.d.ts",
|
|
@@ -57,6 +57,7 @@
|
|
|
57
57
|
"format": "prettier --write . --ignore-path ../../.prettierignore",
|
|
58
58
|
"build": "tsup",
|
|
59
59
|
"dev": "tsup --watch",
|
|
60
|
-
"test": "vitest run"
|
|
60
|
+
"test": "vitest run",
|
|
61
|
+
"typecheck": "tsc --noEmit"
|
|
61
62
|
}
|
|
62
63
|
}
|
|
File without changes
|