@hasna/skills 0.10.48 → 0.10.50

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.
@@ -7,7 +7,7 @@ export { captureDiscoveryDirectories, type DiscoveryDirectory } from "./agent-di
7
7
  export interface DiscoverySource {
8
8
  path: string;
9
9
  sha256: string | null;
10
- hashMode?: "bytes" | "path-bytes" | "claude-plugin-manifest-v1" | "claude-plugin-registry" | "claude-marketplace-registry" | "claude-settings-v1" | "claude-settings-v2" | "claude-settings-v3" | "claude-marketplace-registry-v2" | "codex-settings-v1" | "codex-settings-v2" | "codex-settings-v3" | "codex-settings-v4" | "sumi-settings-v1";
10
+ hashMode?: "bytes" | "path-bytes" | "claude-plugin-manifest-v1" | "claude-plugin-registry" | "claude-marketplace-registry" | "claude-settings-v1" | "claude-settings-v2" | "claude-settings-v3" | "claude-settings-v4" | "claude-marketplace-registry-v2" | "codex-settings-v1" | "codex-settings-v2" | "codex-settings-v3" | "codex-settings-v4" | "sumi-settings-v1";
11
11
  managedPlugins?: ManagedPluginRegistrationWitness[];
12
12
  format?: "json" | "toml" | "yaml";
13
13
  fields?: string[];
@@ -190,6 +190,7 @@ export declare function planClaudeHookEventsUpdate(options: ClaudeHookUpdateOpti
190
190
  export declare function planAgentSettingsWitnessUpgrade(options: {
191
191
  agent: "claude" | "codex" | "sumi";
192
192
  targetCodexVersion?: 2 | 3 | 4;
193
+ targetClaudeVersion?: 3 | 4;
193
194
  reviewedPreimage: string;
194
195
  home?: string;
195
196
  dataDir?: string;
@@ -10,6 +10,7 @@ export interface ClaudeSettingsWitnessBudget {
10
10
  remaining: number;
11
11
  }
12
12
  export declare function readNativeSettingsWitnessFile(path: string, budget: ClaudeSettingsWitnessBudget, filename?: "settings.json" | "config.toml" | "sumi.json"): string;
13
+ export declare const CLAUDE_BUILTIN_THEMES: readonly ["auto", "dark", "light", "dark-daltonized", "light-daltonized", "dark-ansi", "light-ansi"];
13
14
  /** Cooperating installers may replace only their explicitly selected event. Compare the strict syntax
14
15
  * trees, not JSON.parse values or the preference-tolerant witness digest: all
15
16
  * other hooks, discovery settings, unknown values and number spellings remain
@@ -51,6 +52,24 @@ export declare function upgradeClaudeSettingsWitness(previous: {
51
52
  hashMode?: "bytes" | "claude-settings-v1" | "claude-settings-v2";
52
53
  sha256: string;
53
54
  }, reviewedSettingsPath: string): ReturnType<typeof captureClaudeSettingsV3>;
55
+ /** Explicit review that additionally permits a built-in top-level theme.
56
+ * v1/v2/v3 witnesses keep their meaning; nothing selects v4 implicitly. */
57
+ export declare function captureClaudeSettingsV4(path: string, budget?: ClaudeSettingsWitnessBudget): {
58
+ path: string;
59
+ hashMode: "claude-settings-v4";
60
+ sha256: string;
61
+ };
62
+ export declare function hashClaudeSettingsReplacementV4(text: string, budget: ClaudeSettingsWitnessBudget): string;
63
+ /** Explicit opt-in upgrade to v4 with an exact preserved preimage of the prior
64
+ * review (raw bytes, v1, v2 or v3). It proves that every setting v4 binds is
65
+ * unchanged; any other drift, including skipDangerousModePermissionPrompt,
66
+ * refuses. A stored witness is never rewritten without this call.
67
+ */
68
+ export declare function upgradeClaudeSettingsWitnessV4(previous: {
69
+ path: string;
70
+ hashMode?: "bytes" | "claude-settings-v1" | "claude-settings-v2" | "claude-settings-v3";
71
+ sha256: string;
72
+ }, reviewedSettingsPath: string): ReturnType<typeof captureClaudeSettingsV4>;
54
73
  /** Strict bounded JSON control witness; metadata exclusion must be explicit. */
55
74
  export declare function hashNativeJsonControls(text: string, excludedMetadata?: "version"): string;
56
75
  /** Sumi's versioned review uses the same strict JSON parser and bounded syntax
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,5 @@
1
+ export declare const LAUNCH_CWD_VARIABLE = "HASNA_SKILLS_LAUNCH_CWD";
2
+ export declare function restoreLaunchCwd(env?: Record<string, string | undefined>): {
3
+ restored: boolean;
4
+ cwd: string;
5
+ };
@@ -0,0 +1,21 @@
1
+ /**
2
+ * The trusted directory for a child of `entry`: the copyfile runtime version
3
+ * root that holds `node_modules/@hasna/skills` (what the pinned launcher uses),
4
+ * or the entry's own directory for a build or source checkout.
5
+ */
6
+ export declare function selfSpawnRoot(entry: string): string;
7
+ export interface SelfSpawnCommand {
8
+ command: string[];
9
+ cwd: string;
10
+ env: Record<string, string>;
11
+ }
12
+ /**
13
+ * Argv, working directory and environment to run this Skills entry again with
14
+ * `args`. Pass the result to Bun.spawn as `cmd`, `cwd` and `env`.
15
+ */
16
+ export declare function selfSpawnCommand(args: readonly string[], options?: {
17
+ entry?: string;
18
+ runtime?: string;
19
+ env?: Record<string, string | undefined>;
20
+ callerCwd?: string;
21
+ }): SelfSpawnCommand;
@@ -8,6 +8,7 @@
8
8
  * skills-mcp # Direct binary
9
9
  * skills-mcp --http # Streamable HTTP on 127.0.0.1:8836
10
10
  */
11
+ import "../lib/launch-cwd-apply.js";
11
12
  /**
12
13
  * FAIL CLOSED AT STARTUP (owner ruling 2026-09-04, hasna/apps#1720; #1720
13
14
  * validation, round 1): the MCP process resolves the fleet ladder BEFORE it