@mushi-mushi/cli 0.18.0 → 0.18.2
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/CONTRIBUTING.md +27 -8
- package/README.md +8 -5
- package/dist/{chunk-S4WQHEGH.js → chunk-7Q44KWGN.js} +77 -51
- package/dist/chunk-A2NHESSJ.js +313 -0
- package/dist/chunk-E4IZPV6D.js +6 -0
- package/dist/chunk-LDPFTQLE.js +44 -0
- package/dist/cli-shared-XH3XYIS7.js +18 -0
- package/dist/detect.d.ts +1 -1
- package/dist/detect.js +1 -1
- package/dist/endpoint-DGS73AVM.js +15 -0
- package/dist/index.js +330 -560
- package/dist/init.js +5 -5
- package/dist/version.js +1 -1
- package/package.json +6 -6
- package/dist/chunk-ZB6ITDCQ.js +0 -6
package/dist/init.js
CHANGED
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
envVarsToWrite,
|
|
6
6
|
installCommand,
|
|
7
7
|
readPackageJson
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-7Q44KWGN.js";
|
|
9
9
|
import {
|
|
10
10
|
MUSHI_CLI_VERSION
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-E4IZPV6D.js";
|
|
12
12
|
|
|
13
13
|
// src/init.ts
|
|
14
14
|
import * as p from "@clack/prompts";
|
|
@@ -289,7 +289,7 @@ function getFrameworkFromPkg(pkg) {
|
|
|
289
289
|
// src/init.ts
|
|
290
290
|
var ENV_FILES = [".env.local", ".env"];
|
|
291
291
|
var PROJECT_ID_PATTERN = /^(?:proj_[A-Za-z0-9_-]{10,}|[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12})$/i;
|
|
292
|
-
var API_KEY_PATTERN = /^mushi_[A-Za-z0-9_-]{10,}$/;
|
|
292
|
+
var API_KEY_PATTERN = /^(mushi_|mush_pk_)[A-Za-z0-9_-]{10,}$/;
|
|
293
293
|
async function runInit(options = {}) {
|
|
294
294
|
const cwd = options.cwd ?? process.cwd();
|
|
295
295
|
ensureInteractiveOrBailOut(options);
|
|
@@ -501,8 +501,8 @@ function persistCliConfig(apiKey, projectId, endpoint) {
|
|
|
501
501
|
const existing = loadConfig();
|
|
502
502
|
saveConfig({ ...existing, apiKey, projectId, endpoint });
|
|
503
503
|
}
|
|
504
|
-
function printNextSteps(framework,
|
|
505
|
-
p.note(framework.snippet(
|
|
504
|
+
function printNextSteps(framework, _apiKey, _projectId, enableRewards = false) {
|
|
505
|
+
p.note(framework.snippet(), "Add this to your app:");
|
|
506
506
|
if (enableRewards) {
|
|
507
507
|
const badgeSnippet = framework.id === "react" ? `// Add to your user menu or profile UI:
|
|
508
508
|
import { MushiRewardsBadge } from '@mushi-mushi/react';
|
package/dist/version.js
CHANGED
package/package.json
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mushi-mushi/cli",
|
|
3
|
-
"version": "0.18.
|
|
3
|
+
"version": "0.18.2",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "CLI for Mushi Mushi — `mushi init` wizard installs the right SDK for your framework, plus report triage and pipeline health commands",
|
|
6
6
|
"bin": {
|
|
7
7
|
"mushi": "./dist/index.js"
|
|
8
8
|
},
|
|
9
9
|
"dependencies": {
|
|
10
|
-
"@clack/prompts": "^1.
|
|
11
|
-
"commander": "^
|
|
10
|
+
"@clack/prompts": "^1.5.1",
|
|
11
|
+
"commander": "^15.0.0"
|
|
12
12
|
},
|
|
13
13
|
"devDependencies": {
|
|
14
|
-
"@types/node": "^22.19.
|
|
15
|
-
"eslint": "^10.
|
|
14
|
+
"@types/node": "^22.19.21",
|
|
15
|
+
"eslint": "^10.4.1",
|
|
16
16
|
"tsup": "^8.5.1",
|
|
17
17
|
"typescript": "^6.0.3",
|
|
18
|
-
"vitest": "^4.1.
|
|
18
|
+
"vitest": "^4.1.8",
|
|
19
19
|
"@mushi-mushi/eslint-config": "0.0.0"
|
|
20
20
|
},
|
|
21
21
|
"author": "Kenji Sakuramoto",
|