/** * Shared config-fingerprint helpers for the tree-sitter adapters' * `cacheKey`. * * `hashConfig(configPathAbs)` is byte-identical in graph-go / graph-java / * graph-rust: it returns the literal `no-config` when no anchor exists, * `missing:` / `unreadable:` sentinels on fs failure, and the * first 16 hex chars of the sha256 of the manifest content otherwise. Per * contract invariant I-6 it is a pure function of the config content. * * `makeConfigCacheKey({ prefix })` returns the trivial * `cacheKey(input) => `${prefix}-${hashConfig(...)}`` used by go/java/rust * (with prefixes `go-` / `java-` / `rs-`). Python keeps its own * `cache-key.ts` but imports `hashConfig` from here and layers its * `requires-python` extraction on top (DEC-4). */ import type { CacheKeyInput } from '@opensip-tools/graph'; /** * Fingerprint a language config file's content. * * - `undefined` / empty path → `'no-config'` * - path does not exist → `'missing:'` * - read fails → `'unreadable:'` * - otherwise → first 16 hex of sha256(content) */ export declare function hashConfig(configPathAbs: string | undefined): string; /** * Builds a `cacheKey` that emits `${prefix}-${hashConfig(configPathAbs)}`. * Per I-8 the prefix must be distinct per adapter (`go-`, `java-`, `rs-`). */ export declare function makeConfigCacheKey(options: { readonly prefix: string; }): (input: CacheKeyInput) => string; //# sourceMappingURL=cache-key.d.ts.map