Files
renovate/lib/util/cache/repository/schema.ts
Sebastian Poxhofer 914c64afbd test(linter): zod schema and infered type naming rule (#43736)
* ci: add linting rule for schema and infered types

* refactor: remove usages of Schema and differently named types
2026-06-02 12:07:35 +00:00

17 lines
422 B
TypeScript

import { z } from 'zod/v4';
import { Json } from '../../schema-utils/index.ts';
export const RepoCacheRecord = Json.pipe(
z
.object({
repository: z.string().min(1),
revision: z.number().refine((v) => v === 13),
payload: z.string().min(1),
hash: z.string().min(1),
fingerprint: z.string().min(1),
})
.strict(),
);
export type RepoCacheRecord = z.infer<typeof RepoCacheRecord>;