@hasna/skills 0.8.10 → 0.8.12

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.
@@ -173,6 +173,96 @@ new loaders still require their dedicated review. API failure refuses an update;
173
173
  stale projection as synchronized. Claude may retain its previous installation
174
174
  after a refused update, whose existing local drift checks continue to apply.
175
175
 
176
+ ## Marketplace registry timestamps
177
+
178
+ For an explicitly reviewed `known_marketplaces.json`,
179
+ `captureClaudeMarketplaceRegistry(path)` emits a separate
180
+ `claude-marketplace-registry` witness. It preserves every marketplace name,
181
+ source, install location and unknown value. Only a valid UTC `lastUpdated`
182
+ timestamp can vary, and only for exact rows containing `source`,
183
+ `installLocation` and `lastUpdated`, with a recognized GitHub repository or local
184
+ directory source. Rows with any extra field, including `autoUpdate`, retain
185
+ their entire contents in the digest. Registration changes still refuse.
186
+
187
+ This mode is opt-in for reviewed Claude discovery. It cannot project fields,
188
+ carry managed-plugin rules, accept an absent registry or synthesize registry
189
+ changes during hook installation. It does not replace the separate settings,
190
+ installed-plugin, marketplace catalog, loader, root or payload witnesses.
191
+ Capture requires a bounded regular file with strict UTF-8 and unambiguous JSON;
192
+ links, duplicate keys and concurrent file replacement refuse.
193
+
194
+ Existing byte witnesses retain their exact behavior. A prior hash mismatch is
195
+ not proof of a timestamp-only change: review the complete current registration
196
+ and its complementary sources before explicitly replacing an old witness.
197
+ Capturing this witness does not write a policy or approve native registration.
198
+
199
+ ## Claude settings preferences
200
+
201
+ `captureClaudeSettings(canonicalSettingsPath)` returns a versioned
202
+ `claude-settings-v1` discovery source for the configured Claude user
203
+ `settings.json`. Use the canonical target when a reviewed home root alias is
204
+ present. The mode is accepted only in explicit reviewed Claude discovery; it
205
+ cannot stand in for a plugin manifest, executable, project settings review or
206
+ another agent's configuration.
207
+
208
+ The digest canonicalizes JSON object key order, preserves array order and
209
+ unknown numeric values without rounding, and excludes only these top-level
210
+ preferences and model selections with valid documented types:
211
+
212
+ - Booleans: `autoScrollEnabled`, `axScreenReader`, `emojiCompletionEnabled`,
213
+ `prefersReducedMotion`, `showTurnDuration`, `spinnerTipsEnabled`,
214
+ `syntaxHighlightingDisabled`, `terminalProgressBarEnabled`,
215
+ `terminalTitleFromRename`, `verbose`, `wheelScrollAccelerationEnabled`.
216
+ - Exact strings: `editorMode` (`normal`, `vim`), `tui` (`default`, `fullscreen`),
217
+ `viewMode` (`default`, `verbose`, `focus`).
218
+ - Built-in `model` values: `default`, `best`, `fable`, `fable[1m]`, `sonnet`,
219
+ `sonnet[1m]`, `opus`, `opus[1m]`, `haiku`, `opusplan`; exact model IDs
220
+ `claude-fable-5-1`, `claude-fable-5`, `claude-fable-5[1m]`, `claude-opus-5`,
221
+ `claude-sonnet-5`, `claude-haiku-4-5-20251001`, `claude-opus-4-6`,
222
+ `claude-sonnet-4-5`, `claude-sonnet-4-5-20250929`, `claude-opus-4-8`,
223
+ `claude-opus-4-8[1m]`, `claude-opus-4-7`, `claude-sonnet-4-6`,
224
+ `claude-opus-4-5-20251101`, `claude-opus-4-5`, `claude-haiku-4-5`,
225
+ `claude-fable-5-1[1m]`, `claude-opus-5[1m]`, `claude-opus-4-7[1m]`,
226
+ `claude-opus-4-6[1m]`, `claude-sonnet-4-6[1m]`.
227
+
228
+ The model exception follows the documented [model picker](https://code.claude.com/docs/en/model-config#setting-your-model)
229
+ and [model IDs](https://platform.claude.com/docs/en/models/overview), including
230
+ the documented [extended-context model-name suffix](https://code.claude.com/docs/en/model-config#extended-context)
231
+ only for the listed supported combinations. It permits
232
+ inference selection among this fixed list, including clearing the override. It
233
+ does not exempt provider or alias mappings, `modelOverrides`, `modelPicker`,
234
+ `modelSettings`, `availableModels`, environment or model-switch hooks. Arbitrary
235
+ custom, provider-specific, future or path-like model strings stay bound; there
236
+ is no prefix wildcard or dynamic model lookup. Non-string model values refuse.
237
+
238
+ Invalid values for the display preferences refuse capture and verification. Every
239
+ other field remains bound, including unknown future fields, hooks and their
240
+ exact commands, permissions, native skill suppression and synchronization,
241
+ plugin roots, marketplaces, environment and configuration precedence. Language,
242
+ output style, theme, and command-bearing status or file suggestion settings are
243
+ intentionally retained. These are narrow preference and inference-selection
244
+ exceptions, not general permission to change Claude configuration. The native
245
+ bridge guard continues to check its exact commands and native Skill policy.
246
+
247
+ Migration requires reviewing the current complete settings and complementary
248
+ plugin/loader sources, replacing the settings raw source with the captured
249
+ typed source in a reviewed discovery-input file, and using the normal hook
250
+ installation plan/apply operation. A stale prior raw hash is not evidence that
251
+ only preferences changed. Capture performs no write or automatic refresh; old
252
+ raw witnesses remain exact. Concurrent changes during an installation still
253
+ face full-byte preconditions so a preference edit cannot be overwritten.
254
+
255
+ The source must be a stable normalized regular file named `settings.json` with
256
+ strict UTF-8, no duplicate JSON keys and no trailing content. Limits are 1 MiB,
257
+ 1,024 top-level fields, depth 32, 65,536 nodes and 16,384 characters per string;
258
+ capture also consumes the shared discovery byte budget. Symlinks, special
259
+ nodes and changes during a read refuse. This witness covers the configured
260
+ user file; existing checks on project settings, root aliases and plugin sources
261
+ remain separate. It does not certify arbitrary command-line settings overrides
262
+ or guarantee when a running native client adopts a settings edit.
263
+ Those complementary checks retain their existing exact registration and hook
264
+ entry comparisons; this mode does not relax them for property-order changes.
265
+
176
266
  ## Verification and limits
177
267
 
178
268
  Unit tests cover provenance and mapping failures, offline/revoked authorities,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hasna/skills",
3
- "version": "0.8.10",
3
+ "version": "0.8.12",
4
4
  "description": "Skills library for AI coding agents",
5
5
  "type": "module",
6
6
  "bin": {
@@ -62,10 +62,11 @@
62
62
  "typecheck": "tsc --noEmit",
63
63
  "verify:release": "bun run scripts/release-guard.ts",
64
64
  "verify:consumer-types": "bun run scripts/consumer-types.ts",
65
- "prepare": "bun run build:js",
66
- "prepack": "bun run build && bun run verify:release && bun run verify:consumer-types",
65
+ "prepack": "bun run verify:generated && bun run verify:release && bun run verify:consumer-types",
67
66
  "prepublishOnly": "bun run verify:producer && bun run typecheck && bun run test",
68
- "verify:producer": "bun run scripts/release-dependencies.ts"
67
+ "verify:producer": "bun run scripts/release-dependencies.ts",
68
+ "verify:generated": "HASNA_SKILLS_RELEASE_ARTIFACT_TEST=1 bun test src/lib/release-artifacts.test.ts",
69
+ "verify:consumer-credentials": "bun run scripts/consumer-credentials.ts"
69
70
  },
70
71
  "keywords": [
71
72
  "skills",
@@ -87,7 +88,6 @@
87
88
  "license": "Apache-2.0",
88
89
  "devDependencies": {
89
90
  "@hasna/contracts": "1.1.0",
90
- "@hasna/secrets": "0.4.2",
91
91
  "@types/bun": "1.3.14",
92
92
  "@types/node": "25.2.3",
93
93
  "@types/react": "^18.2.0",
@@ -100,6 +100,7 @@
100
100
  "@aws-sdk/client-ecs": "^3.1079.0",
101
101
  "@aws-sdk/client-s3": "^3.1079.0",
102
102
  "@hasna/events": "0.1.18",
103
+ "@hasna/secrets": "0.4.2",
103
104
  "@modelcontextprotocol/sdk": "^1.26.0",
104
105
  "chalk": "^5.3.0",
105
106
  "commander": "^12.1.0",