@ait-co/console-cli 0.1.32 → 0.1.33

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.mjs CHANGED
@@ -1974,7 +1974,7 @@ async function runDeploy(args, deps = {}) {
1974
1974
  const release = Boolean(args.release);
1975
1975
  const confirm = Boolean(args.confirm);
1976
1976
  const releaseNotes = typeof args.releaseNotes === "string" ? args.releaseNotes : void 0;
1977
- if (requestReview && releaseNotes === void 0) {
1977
+ if (requestReview && (releaseNotes === void 0 || releaseNotes.trim() === "")) {
1978
1978
  if (args.json) emitJson({
1979
1979
  ok: false,
1980
1980
  reason: "missing-release-notes",
@@ -2510,6 +2510,7 @@ function validateManifest(raw, configDir) {
2510
2510
  if (!isTitleCaseWord(word)) throw new ManifestError("invalid-config", `titleEn word "${word}" must be title-case (first letter uppercase, rest lowercase); server-side rule, errorCode: miniApp.InvalidTitleEn`, "titleEn");
2511
2511
  }
2512
2512
  const appName = requireString(raw, "appName");
2513
+ if (!APP_NAME_REGEX.test(appName)) throw new ManifestError("invalid-config", `appName must be a kebab-case slug starting with a lowercase letter (got "${appName}"; server-side rule)`, "appName");
2513
2514
  const csEmail = requireString(raw, "csEmail");
2514
2515
  if (!isValidEmail$1(csEmail)) throw new ManifestError("invalid-config", `csEmail is not a valid email address (got ${csEmail})`, "csEmail");
2515
2516
  const subtitle = requireString(raw, "subtitle");
@@ -3139,7 +3140,9 @@ async function emitFailureAndExit(json, err) {
3139
3140
  return emitFailureFromError(json, err);
3140
3141
  }
3141
3142
  async function persistMiniAppIdToProject(json, miniAppId, cwd) {
3142
- if (typeof miniAppId !== "number" || !Number.isInteger(miniAppId) || miniAppId <= 0) return;
3143
+ const coerced = typeof miniAppId === "string" && /^\d+$/.test(miniAppId) ? Number(miniAppId) : miniAppId;
3144
+ if (typeof coerced !== "number" || !Number.isInteger(coerced) || coerced <= 0) return;
3145
+ const numericId = coerced;
3143
3146
  let ctx;
3144
3147
  try {
3145
3148
  ctx = await findProjectContext(cwd);
@@ -3151,12 +3154,12 @@ async function persistMiniAppIdToProject(json, miniAppId, cwd) {
3151
3154
  return;
3152
3155
  }
3153
3156
  if (ctx === null) {
3154
- if (!json) process.stderr.write(`tip: drop an aitcc.yaml with \`miniAppId: ${miniAppId}\` in your project root to skip --app on later commands.\n`);
3157
+ if (!json) process.stderr.write(`tip: drop an aitcc.yaml with \`miniAppId: ${numericId}\` in your project root to skip --app on later commands.\n`);
3155
3158
  return;
3156
3159
  }
3157
3160
  try {
3158
- const outcome = await writeProjectMiniAppId(ctx.source, miniAppId);
3159
- if (!json && outcome.status === "written") process.stderr.write(`Updated ${ctx.source} with miniAppId: ${miniAppId}.\n`);
3161
+ const outcome = await writeProjectMiniAppId(ctx.source, numericId);
3162
+ if (!json && outcome.status === "written") process.stderr.write(`Updated ${ctx.source} with miniAppId: ${numericId}.\n`);
3160
3163
  } catch (err) {
3161
3164
  if (!json) {
3162
3165
  const detail = err instanceof Error ? err.message : String(err);
@@ -6218,7 +6221,7 @@ async function clearAuthState() {
6218
6221
  * 2. OS keychain entry whose email is recorded in `auth-state.json`.
6219
6222
  *
6220
6223
  * Returns `null` when no source is configured. The discriminated `kind`
6221
- * lets callers (e.g. PR β's login flow) tell why a credential was found
6224
+ * lets callers (e.g. the login flow) tell why a credential was found
6222
6225
  * without having to peek at process env themselves — useful for
6223
6226
  * "auto-login from CI" diagnostics.
6224
6227
  *
@@ -9229,7 +9232,7 @@ function resolveVersion() {
9229
9232
  if (typeof injected === "string" && injected.length > 0) return injected;
9230
9233
  } catch {}
9231
9234
  try {
9232
- return "0.1.32";
9235
+ return "0.1.33";
9233
9236
  } catch {}
9234
9237
  return "0.0.0-dev";
9235
9238
  }