@theholocron/cli 5.0.0-alpha.502 → 5.0.0-alpha.504

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 CHANGED
@@ -680,7 +680,7 @@ commands and the config are provider-neutral; Discord is the first provider.
680
680
  | `holocron doctor workers` | Do the Workers and deployment projects the config declares exist, route and deploy healthily? Declared Workers are the relay Worker of a notifications layout that feeds an error tracker and the reverse proxy of a wiki with a custom domain. Rows per Worker: `<name> Worker is deployed and routed` (the script exists with a route for its host), `has its bindings` (by name, a value is never read) and `latest deployment is healthy` (the newest deployment serves all traffic). Rows per deployment project (the preview project, else one named like the repo): `<project> project exists`, `has its custom domain` (when one is declared) and `latest deployment is healthy` (the newest production deployment is ready; one that errored fails, one still building is information). Reads through the optional `Workers.inspectScript` / `latestDeployment` / `proxyScriptName` and `Deployment.listProjects` / `listDomains` / `latestDeployment`; never deploys or prints a token. A missing token, a 401 or 403, or a provider that cannot read it is a skip. Read-only |
681
681
  | `holocron doctor environments` | Do the deployment environments exist? The ones `setup` creates (`staging`, `production`, when an `environments` provider is configured) plus every environment `repo.secrets.environments` names. One row. A missing one fails; an extra one is never a problem; no provider with some named is a skip |
682
682
  | `holocron doctor project [--post [channel]]` | Does each board `providers.projects.boards` declares exist and match its template? One row per board, status list, field, view and automation rule; the board's extras and the items `reconcile project` would fix (no status, closed but not done, open blocker but not blocked, blocked without a blocker) are `info` rows, never a failure. A template file that does not read fails, naming the file. Read-only; `--post` shares the failing rows through the `notifications` bot. |
683
- | `holocron doctor repo` | Do the repository settings `setup` writes match the config? One row per group the config declares: description and homepage, default branch and merge settings, topics, custom properties, team access, branch protection; labels and security settings are always checked. Read-only. Reads through optional `Source` methods (`getRepoInfo`, `getProperties`, `listLabels`, `listTeamAccess`, `getRulesetDetail`, `getSecurity`); a group that cannot be read is a skip, not a failure |
683
+ | `holocron doctor repo` | Do the repository settings `setup` writes match the config? One row per group the config declares: description and homepage, default branch and merge settings, topics, custom properties, team access, branch protection; labels and security settings are always checked, plus a `repo-area-labels` row when `repo.labels.areas` is declared (a declared area with no `area:<name>` label fails; an undeclared `area:` label is an `info` note). Read-only. Reads through optional `Source` methods (`getRepoInfo`, `getProperties`, `listLabels`, `listTeamAccess`, `getRulesetDetail`, `getSecurity`); a group that cannot be read is a skip, not a failure |
684
684
  | `holocron doctor dns` | Do the DNS records the config makes setup write exist, pointing where they should? The preview domain's apex and wildcard CNAMEs (Cloudflare), the docs site a wiki provider asks for, and the relay Worker's proxied placeholder; one row per zone. A missing record, another target or a missing proxy fails; an extra record never does. A record `ensureCustomDomain()` returns is not checked, because asking for it creates the domain |
685
685
  | `holocron doctor monitoring` | Do the checks the `monitoring` provider declares exist in its account, matched by name, with the URL, method and (when stated) frequency, locations, tags (a declared tag the check lacks fails; an extra one does not), activated, should-fail, body and assertions the config sets? One row. A check in the account that is not declared is never a problem. A provider that cannot list its checks, could not load or has no token is a skip |
686
686
  | `holocron doctor secrets [--env <list>] [--only-secrets \| --only-variables] [--strict] [--name <name>] [--verify] [--shared [--allow NAME]...]` | Prints a matrix of every secret and variable by place (1Password Environments, GitHub, deployments; names only, cells `ok`, `n/a`, `MISSING`, `extra`, `?`) and checks the declared ones. `MISSING` fails; `extra` is info (`--strict` fails; `doctor.manualSecrets` is left out); `--name` explains one name and exits 0 (this and `extra` replace `doctor variable-owners`). `--shared` compares the layers named by `--env` (two or more of `local`, `dev`, `ci`, `prod`; all four by default) for a secret that holds the same value in two of them: it reads each Environment in memory, compares the concealed entries by a salted hash made fresh per run, and prints names only, one row per pair of layers (`info`, shown as skipped; `--strict` fails), plus `info` rows for `ci` variables missing from or different in `dev`; `doctor.sharedVariables` and `--allow` leave out names shared on purpose (the old `doctor secrets`). `--verify` also asks each vendor whether the tokens the plugins take are still accepted (online; fails a rejected token or one with 7 days or fewer left; the old `doctor tokens`). It also checks `repo.variables` (the old `doctor variables`). Do the secrets the config says must exist (`repo.secrets`, plus the notification layout's webhook and role secrets and the Chromatic token) exist? One row for the repository, the organization and each environment, each only when something is expected there. Names only; an undeclared secret is never a problem. `--env` takes a comma-separated or repeated list of `local`, `dev`, `ci`, `test`, `prod` and checks only those (`ci` the GitHub secrets, `prod` the deploy destinations; `local`, `dev` and `test` are a skipped row that says why). A scope that cannot be read is a skip |
@@ -762,6 +762,7 @@ See the [command pages](https://theholocron.dev/holocron/commands/setup-notifica
762
762
  - **`holocron new work <title> [--spec [name]] [--effort high|medium|low] [--assignee <login>]...` plus every `new issue` flag `[--dry-run] [--yes]`** — files the issue with all its fields (it calls `runIssueCreate()`, so the fields, `--project`, `--area`, the confirmation and `--dry-run` are `new issue`'s) and, with `--spec`, writes the draft spec stub `.notes/<name>.spec.md` from it (`runIdeasPromote()`, the `new spec` path; the name defaults to `tech-<title>`). The assignee defaults to the GitHub login in git's config (`github.user`, else a `users.noreply.github.com` email; never the token's identity), `--assignee` overrides it, and with no login the issue is filed unassigned and a row says so. Effort is asked on a terminal when `--effort` is absent (not with `--yes` or `--dry-run`); an agent passes it. It makes no branch and no commit: the last line names `holocron start work <key> --spec <path>`, which makes the spec the first commit. The spec's name and path are checked before the issue is filed.
763
763
  - **`holocron start work <issue> [--name <slug>] [--title <text>] [--base <branch>] [--no-worktree] [--worktree-path <path>] [--spec <file>] [--one-pr] [--type bug|feature|task] [--effort high|medium|low] [--assignee <login>]... [--project <board>] [--no-pr] [--dry-run] [--yes]`** — starts a piece of work (spec `tool-work-commands`, #2429, part 3): reads the issue, sets its start date (and Effort), makes the branch `<type>/<issue>-<slug>` and a worktree under `.claude/worktrees/<name>`, makes the first commit (the spec file, or an empty commit titled like the pull request), pushes, and opens a draft pull request linked to the issue (`Closes`, or `Refs` for a spec-only pull request). It asks first unless `--dry-run` or `--yes`; `--dry-run` runs only the reads and writes nothing, local version control included. Run again, it carries on from the first undone step. The board status is left to the open pull request. See `docs/src/content/docs/commands/start-work.mdx`.
764
764
  - **`holocron update work <issue> [--title <text>] [--issue-title <text>] [--label <name>]... [--remove-label <name>]... [--assignee <login>]... [--milestone <title>] [--unblock <key>]... [--pr <number>] [--start [--name <slug>] [--base <branch>] [--spec <file>] [--one-pr]] [--status <status> [--force] [--board <name>]]` plus the `update issue` field flags `[--dry-run] [--yes]`** — keeps the issue, its pull request and the board in step (spec `tool-work-commands`, part 5). It finds the open pull request by its `<type>/<issue>-<slug>` branch (or `--pr`), updates the issue through `Issues.update` and the pull request's title, labels, assignees, milestone and board through `Source.updatePullRequest`, and adds the `area:<name>` labels the pull request's changed folders earn (`repo.labels.areas`; `Source.listPullRequestFiles`) to both, never removing a label. `--start` runs `start work` first. `--status` is last and refuses In Review, Blocked and Done without `--force` (the board's automation owns them); any hand-set status is temporary. Asks once first unless `--dry-run` or `--yes`.
765
+ - **Area labels** (`repo.labels`, spec `tech-github-area-labels`, #2430 part 2). `repo.labels.areas` (name to folder patterns, `!` excludes) and `repo.labels.scopes` (title scope to area) are checked when the config loads (`validateRepoLabels()`, a `ConfigError` naming `repo.labels.areas.<name>`). `holocron setup` makes the declared `area:<name>` labels through the optional `Source.ensureLabels()` (create only, `--dry-run` writes nothing; they are never in `CANONICAL_LABELS` or `STALE_LABELS`), and `doctor repo` has a `repo-area-labels` row. The one mapping is exported from `@theholocron/cli` for Sentinel and the backfill probe: `areaLabelsForFiles(files, areas)`, `areaLabelsForTitle(title, scopes)`, `areaForScope(scope, scopes)`, `titleScopes(title)`, `pathMatches(path, pattern)`, `areaLabelDefs(areas)` and `AREA_PREFIX`.
765
766
  - **`holocron close work <issue> [--wait [--timeout <minutes>]] [--abandon] [--keep-worktree] [--pr <number>] [--dry-run] [--yes]`** — the end of a piece of work (spec `tool-work-commands`, part 6). It never merges. For an open pull request it reads the `ci / Required checks` aggregate through the optional `Source.getPullRequestChecks` (with `--wait`, polling until green or red or `--timeout` minutes, default 30), stops on anything but green naming the failing checks, and on green asks, marks the pull request ready (`Source.markReady`), adds the area labels through `update work` and takes closed blockers off the issue. Run again after the merge it removes the worktree and the local branch (never forced; `--keep-worktree` leaves them) and checks the remote branch is gone. `--abandon` always asks, stops when the branch holds unpushed commits, closes the pull request, withdraws the spec's post (`sync specs --withdraw`), removes the worktree and branch and asks whether to close the issue as not planned. `--dry-run` writes nothing, local git included.
766
767
 
767
768
  ## Syncing tooling
@@ -778,7 +779,8 @@ See the [command pages](https://theholocron.dev/holocron/commands/setup-notifica
778
779
 
779
780
  - **`holocron sync issues --from <a> --to <b> [--since <time>] [--yes]`** — one direction of an issue sync between two
780
781
  trackers (`github`, `linear:team=ENG`); swap the ends for the other direction. Unlike `holocron migrate` it updates what
781
- it made: it creates a missing issue, sets title, description, state, priority, labels and assignee when they differ, and
782
+ it made: it creates a missing issue, sets title, description, state, priority, labels, kind (the GitHub Type, the kind
783
+ label on Linear; `IssueRecord.kind`) and assignee when they differ, and
782
784
  adds the comments the target lacks (oldest first, never edited or deleted). It writes nothing to the source, and changes
783
785
  a target issue only when a migrate or sync made it (the recorded `holocron:migrated-from` marker or attachment). A source
784
786
  issue that itself carries such an address is skipped, which stops the two directions echoing each other. The report
package/dist/cli.mjs CHANGED
@@ -2687,6 +2687,44 @@ function validateEnvironmentChoice(entry, what, required = true) {
2687
2687
  }
2688
2688
  if (required) throw new ConfigError$1(`${what} needs the name of a vault environment (\`environment\`) or a \`layer\``);
2689
2689
  }
2690
+ // src/config/validate-repo-labels/validate-repo-labels.ts
2691
+ /** What an area name may be: the rest of `area:<name>`, so no colon, comma, space or leading symbol. */
2692
+ const AREA_NAME = /^[A-Za-z0-9][A-Za-z0-9._-]*$/;
2693
+ /** GitHub's longest label name is 50 characters, and `area:` takes five. */
2694
+ const MAX_NAME = 45;
2695
+ /**
2696
+ * Check `repo.labels` (spec `tech-github-area-labels`): each area name must be usable as the suffix of a label (letters,
2697
+ * digits, `.`, `_` and `-`, at most 45 characters) and appear once whatever the case (GitHub's labels are
2698
+ * case-insensitive), each area needs a list of patterns with at least one that includes a path, and each scope names a
2699
+ * declared area.
2700
+ *
2701
+ * @param labels - `repo.labels`, if the config has it.
2702
+ * @throws {ConfigError} Naming the path of the first problem found.
2703
+ */
2704
+ function validateRepoLabels(labels) {
2705
+ if (labels === void 0) return;
2706
+ const areas = labels.areas ?? {};
2707
+ const seen = /* @__PURE__ */ new Map();
2708
+ for (const [name, patterns] of Object.entries(areas)) {
2709
+ const at = `\`repo.labels.areas.${name}\``;
2710
+ if (!AREA_NAME.test(name) || name.length > MAX_NAME) throw new ConfigError$1(`${at}: ${JSON.stringify(name)} cannot be the name of an \`area:<name>\` label (use letters, digits, ".", "_" or "-", at most ${MAX_NAME} characters)`);
2711
+ const lower = name.toLowerCase();
2712
+ const first = seen.get(lower);
2713
+ if (first !== void 0) throw new ConfigError$1(`${at}: duplicates \`repo.labels.areas.${first}\` (label names ignore case)`);
2714
+ seen.set(lower, name);
2715
+ if (!Array.isArray(patterns) || patterns.length === 0) throw new ConfigError$1(`${at} needs a list of folder patterns, got none`);
2716
+ for (const pattern of patterns) if (typeof pattern !== "string" || pattern.replace(/^!/, "").trim() === "") throw new ConfigError$1(`${at} has an empty pattern`);
2717
+ if (patterns.every((p) => p.startsWith("!"))) throw new ConfigError$1(`${at} has only exclusions ("!..."), so no path could be in it`);
2718
+ }
2719
+ for (const [scope, area] of Object.entries(labels.scopes ?? {})) {
2720
+ const at = `\`repo.labels.scopes.${scope}\``;
2721
+ if (scope.trim() === "") throw new ConfigError$1("`repo.labels.scopes` has an empty scope name");
2722
+ if (typeof area !== "string" || !Object.hasOwn(areas, area)) {
2723
+ const known = Object.keys(areas);
2724
+ throw new ConfigError$1(`${at} names the unknown area ${JSON.stringify(area)}; ${known.length > 0 ? `the declared areas are ${known.join(", ")}` : "`repo.labels.areas` declares none"}`);
2725
+ }
2726
+ }
2727
+ }
2690
2728
  // src/credentials-environments/repo-slug/repo-slug.ts
2691
2729
  /**
2692
2730
  * The `<org>/<repo>` of the repository at `cwd`, from its `origin` remote. A remote that is missing or cannot be
@@ -2971,6 +3009,7 @@ function resolveConfig(raw) {
2971
3009
  if (raw.dev !== void 0) validateDev(raw.dev);
2972
3010
  if (raw.githubApps !== void 0) validateGitHubApps(raw.githubApps);
2973
3011
  if (raw.ideas !== void 0) validateIdeas(raw.ideas);
3012
+ validateRepoLabels(raw.repo?.labels);
2974
3013
  validateVariablesSync(raw.repo?.variables);
2975
3014
  validateSecretsDeploy(raw.repo?.secrets);
2976
3015
  validateSecretsSync(raw.repo?.secrets);
@@ -3659,6 +3698,7 @@ const system = createPluginSystem({
3659
3698
  return {
3660
3699
  ...config.repo?.name ? { repo: config.repo.name } : {},
3661
3700
  ...config.repoValidation?.docsCoverage ? { docsCoverage: config.repoValidation.docsCoverage } : {},
3701
+ ...config.repo?.labels ? { areaLabels: config.repo.labels } : {},
3662
3702
  ...context,
3663
3703
  ...effectiveToken !== void 0 ? { cliToken: effectiveToken } : {},
3664
3704
  cliTokens: void 0,
@@ -6317,9 +6357,10 @@ function isIsoDate(value) {
6317
6357
  const date = /* @__PURE__ */ new Date(`${value}T00:00:00Z`);
6318
6358
  return !Number.isNaN(date.getTime()) && date.toISOString().slice(0, 10) === value;
6319
6359
  }
6320
- // src/commands/issue-fields/resolve-area-labels/resolve-area-labels.ts
6360
+ // src/area-labels/area-prefix/area-prefix.ts
6321
6361
  /** The prefix of an area label (spec `tech-github-area-labels`): `area:cli`. */
6322
6362
  const AREA_PREFIX = "area:";
6363
+ // src/commands/issue-fields/resolve-area-labels/resolve-area-labels.ts
6323
6364
  /**
6324
6365
  * Turns area names into their labels, checking each against the areas the repo declares in `repo.labels.areas`. A name
6325
6366
  * is matched without regard to case and may be given with its `area:` prefix. A repo that declares no areas, or a name it
@@ -6833,6 +6874,72 @@ function findWorkPullRequests(prs, issue) {
6833
6874
  return slash > 0 && pr.branch.slice(slash + 1).toLowerCase().startsWith(prefix);
6834
6875
  });
6835
6876
  }
6877
+ // src/area-labels/area-label-defs/area-label-defs.ts
6878
+ /** The colour of every area label: one family, one colour (spec `tech-github-area-labels`). */
6879
+ const AREA_LABEL_COLOR = "c5def5";
6880
+ /** GitHub refuses a label description longer than this. */
6881
+ const MAX_DESCRIPTION = 100;
6882
+ /**
6883
+ * The labels `holocron setup` makes for the areas a repo declares: `area:<name>`, the one family colour and the
6884
+ * description `Changes under <paths>` from the area's own (not excluded) patterns, cut to GitHub's 100 characters. They
6885
+ * are never part of `CANONICAL_LABELS`: an area names this repo's folders, so another repo has none of them.
6886
+ */
6887
+ function areaLabelDefs(areas) {
6888
+ return Object.entries(areas ?? {}).map(([name, patterns]) => {
6889
+ const text = `Changes under ${patterns.filter((p) => !p.startsWith("!")).join(", ")}`;
6890
+ const description = text.length > MAX_DESCRIPTION ? `${text.slice(0, 99)}…` : text;
6891
+ return {
6892
+ name: `${AREA_PREFIX}${name}`,
6893
+ color: AREA_LABEL_COLOR,
6894
+ description
6895
+ };
6896
+ });
6897
+ }
6898
+ // src/area-labels/path-matches/path-matches.ts
6899
+ /** Turns one glob into the expression a whole path must match: `**` crosses folders, `*` and `?` stay in one. */
6900
+ function globToRegExp(glob) {
6901
+ let out = "";
6902
+ for (let i = 0; i < glob.length; i++) {
6903
+ const c = glob.charAt(i);
6904
+ if (c === "*") {
6905
+ if (glob.charAt(i + 1) === "*") {
6906
+ const slash = glob.charAt(i + 2) === "/";
6907
+ out += slash ? "(?:.*/)?" : ".*";
6908
+ i += slash ? 2 : 1;
6909
+ } else out += "[^/]*";
6910
+ } else if (c === "?") out += "[^/]";
6911
+ else out += c.replace(/[.+^${}()|[\]\\]/g, "\\$&");
6912
+ }
6913
+ return new RegExp(`^${out}$`);
6914
+ }
6915
+ /**
6916
+ * Whether a repository path (forward slashes, from the root) matches one pattern of `repo.labels.areas`. A pattern with
6917
+ * a `*` or `?` is a glob (`cli/**`, `docs/**` then `/*.md`); one without is a file (`turbo.json`) or a folder and
6918
+ * everything under it (`.holocron`, `.holocron/`).
6919
+ */
6920
+ function pathMatches(path, pattern) {
6921
+ const clean = path.replace(/^\.?\//, "");
6922
+ if (/[*?]/.test(pattern)) return globToRegExp(pattern.replace(/^\.?\//, "")).test(clean);
6923
+ const plain = pattern.replace(/^\.?\//, "").replace(/\/+$/, "");
6924
+ return clean === plain || clean.startsWith(`${plain}/`);
6925
+ }
6926
+ // src/area-labels/area-labels-for-files/area-labels-for-files.ts
6927
+ /**
6928
+ * The `area:<name>` labels a set of changed paths earns, in the order the areas are declared (spec
6929
+ * `tech-github-area-labels`). An area's patterns are the ones in `repo.labels.areas`; one starting with `!` takes a path
6930
+ * out of the area (`docs/**` with `!docs/wiki/**`), so a path is in an area when some pattern includes it and none
6931
+ * excludes it. A path in no area earns nothing, which is right, not a failure. This is the one mapping from changed
6932
+ * folders to labels in the CLI; Sentinel's `planAreaLabels()` is meant to agree with it.
6933
+ */
6934
+ function areaLabelsForFiles(files, areas) {
6935
+ const labels = [];
6936
+ for (const [name, patterns] of Object.entries(areas ?? {})) {
6937
+ const include = patterns.filter((p) => !p.startsWith("!"));
6938
+ const exclude = patterns.filter((p) => p.startsWith("!")).map((p) => p.slice(1));
6939
+ if (files.some((file) => include.some((p) => pathMatches(file, p)) && !exclude.some((p) => pathMatches(file, p)))) labels.push(`${AREA_PREFIX}${name}`);
6940
+ }
6941
+ return labels;
6942
+ }
6836
6943
  // src/commands/project/open-projects/open-projects.ts
6837
6944
  /**
6838
6945
  * Load the `projects` provider and read its options. A config without `providers.projects`, a provider that did not
@@ -7431,51 +7538,6 @@ async function runStartWork(input) {
7431
7538
  rows.push(row$28("board status", "skip", "not set: the open pull request moves the issue to In Progress; `update work --status` sets it by hand while the automation is down"));
7432
7539
  return finish();
7433
7540
  }
7434
- // src/commands/update-work/path-matches/path-matches.ts
7435
- /** Turns one glob into the expression a whole path must match: `**` crosses folders, `*` and `?` stay in one. */
7436
- function globToRegExp(glob) {
7437
- let out = "";
7438
- for (let i = 0; i < glob.length; i++) {
7439
- const c = glob.charAt(i);
7440
- if (c === "*") {
7441
- if (glob.charAt(i + 1) === "*") {
7442
- const slash = glob.charAt(i + 2) === "/";
7443
- out += slash ? "(?:.*/)?" : ".*";
7444
- i += slash ? 2 : 1;
7445
- } else out += "[^/]*";
7446
- } else if (c === "?") out += "[^/]";
7447
- else out += c.replace(/[.+^${}()|[\]\\]/g, "\\$&");
7448
- }
7449
- return new RegExp(`^${out}$`);
7450
- }
7451
- /**
7452
- * Whether a repository path (forward slashes, from the root) matches one pattern of `repo.labels.areas`. A pattern with
7453
- * a `*` or `?` is a glob (`cli/**`, `docs/**` then `/*.md`); one without is a file (`turbo.json`) or a folder and
7454
- * everything under it (`.holocron`, `.holocron/`).
7455
- */
7456
- function pathMatches(path, pattern) {
7457
- const clean = path.replace(/^\.?\//, "");
7458
- if (/[*?]/.test(pattern)) return globToRegExp(pattern.replace(/^\.?\//, "")).test(clean);
7459
- const plain = pattern.replace(/^\.?\//, "").replace(/\/+$/, "");
7460
- return clean === plain || clean.startsWith(`${plain}/`);
7461
- }
7462
- // src/commands/update-work/area-labels-for-files/area-labels-for-files.ts
7463
- /**
7464
- * The `area:<name>` labels a set of changed paths earns, in the order the areas are declared (spec
7465
- * `tech-github-area-labels`). An area's patterns are the ones in `repo.labels.areas`; one starting with `!` takes a path
7466
- * out of the area (`docs/**` with `!docs/wiki/**`), so a path is in an area when some pattern includes it and none
7467
- * excludes it. A path in no area earns nothing, which is right, not a failure. This is the one mapping from changed
7468
- * folders to labels in the CLI; Sentinel's `planAreaLabels()` is meant to agree with it.
7469
- */
7470
- function areaLabelsForFiles(files, areas) {
7471
- const labels = [];
7472
- for (const [name, patterns] of Object.entries(areas ?? {})) {
7473
- const include = patterns.filter((p) => !p.startsWith("!"));
7474
- const exclude = patterns.filter((p) => p.startsWith("!")).map((p) => p.slice(1));
7475
- if (files.some((file) => include.some((p) => pathMatches(file, p)) && !exclude.some((p) => pathMatches(file, p)))) labels.push(`${AREA_PREFIX}${name}`);
7476
- }
7477
- return labels;
7478
- }
7479
7541
  // src/commands/update-work/guard-work-status/guard-work-status.ts
7480
7542
  /** The statuses the board's rules own (`planReconcile()`, `planPullRequestStatus()`), lower-cased with single spaces. */
7481
7543
  const AUTOMATED_STATUSES = [
@@ -15297,6 +15359,11 @@ const CANONICAL_LABELS = [
15297
15359
  color: "a2eeef",
15298
15360
  description: "New feature or request"
15299
15361
  },
15362
+ {
15363
+ name: "epic",
15364
+ color: "5319e7",
15365
+ description: "A body of work made of several issues"
15366
+ },
15300
15367
  {
15301
15368
  name: "good first issue",
15302
15369
  color: "7057ff",
@@ -15520,6 +15587,24 @@ function repoChecks(config, repoRoot, statusContexts) {
15520
15587
  };
15521
15588
  }
15522
15589
  });
15590
+ const areaLabels = areaLabelDefs(repo?.labels?.areas);
15591
+ if (areaLabels.length > 0) checks.push({
15592
+ id: "repo-area-labels",
15593
+ title: "area labels exist",
15594
+ needs: "listLabels",
15595
+ async run(source) {
15596
+ const found = await source.listLabels();
15597
+ const have = new Set(found.map((l) => l.name.toLowerCase()));
15598
+ const declared = new Set(areaLabels.map((l) => l.name.toLowerCase()));
15599
+ const problems = areaLabels.filter((l) => !have.has(l.name.toLowerCase())).map((l) => `missing label ${l.name} (setup makes it)`);
15600
+ const info = found.filter((l) => l.name.toLowerCase().startsWith("area:") && !declared.has(l.name.toLowerCase())).map((l) => `${l.name} is not declared in \`repo.labels.areas\``);
15601
+ return {
15602
+ problems,
15603
+ checked: areaLabels.length,
15604
+ info
15605
+ };
15606
+ }
15607
+ });
15523
15608
  if (repo?.teams && repo.teams.length > 0) {
15524
15609
  const teams = repo.teams;
15525
15610
  checks.push({
@@ -15703,18 +15788,19 @@ function row$17(check, result) {
15703
15788
  detail: result.skip,
15704
15789
  problems: []
15705
15790
  };
15791
+ const note = result.info && result.info.length > 0 ? `; info: ${result.info.join("; ")}` : "";
15706
15792
  if (result.problems.length > 0) return {
15707
15793
  id,
15708
15794
  title,
15709
15795
  status: "fail",
15710
- detail: `${result.problems.length} problem(s)`,
15796
+ detail: `${result.problems.length} problem(s)${note}`,
15711
15797
  problems: result.problems
15712
15798
  };
15713
15799
  return {
15714
15800
  id,
15715
15801
  title,
15716
15802
  status: "ok",
15717
- detail: `${result.checked} of ${result.checked} match`,
15803
+ detail: `${result.checked} of ${result.checked} match${note}`,
15718
15804
  problems: []
15719
15805
  };
15720
15806
  }
@@ -21645,6 +21731,17 @@ async function runSetup(input) {
21645
21731
  }));
21646
21732
  print(formatStep(steps[steps.length - 1]));
21647
21733
  }
21734
+ const areaLabels = areaLabelDefs(repo?.labels?.areas);
21735
+ if (areaLabels.length > 0) {
21736
+ if (source.ensureLabels) steps.push(await runStep("source", "ensure area labels", dryRun, async () => source.ensureLabels(areaLabels)));
21737
+ else steps.push({
21738
+ capability: "source",
21739
+ step: "ensure area labels",
21740
+ status: "skip",
21741
+ message: `the \`${source.providerName}\` provider cannot make labels one by one`
21742
+ });
21743
+ print(formatStep(steps[steps.length - 1]));
21744
+ }
21648
21745
  const properties = {};
21649
21746
  if (effectivePreset && effectivePreset !== "none") properties["holocron_branch_protection_level"] = effectivePreset;
21650
21747
  const isMonorepo = await isWorkspaceRoot(input.context.repoRoot);
@@ -29577,7 +29674,8 @@ const probeCommand = {
29577
29674
  ...argv.warn ? ["--warn"] : [],
29578
29675
  ...argv.files ? ["--files"] : [],
29579
29676
  ...(argv.only ?? []).flatMap((name) => ["--only", String(name)]),
29580
- ...argv.copy ? ["--copy"] : []
29677
+ ...argv.copy ? ["--copy"] : [],
29678
+ ...(argv["--"] ?? []).map(String)
29581
29679
  ];
29582
29680
  if ((await runProbeCommand({
29583
29681
  loaded,