Commit Graph

3 Commits

Author SHA1 Message Date
Michael Kriese 7c0592b540 chore(tools): allow unsafe askpass in agent hooks git config (#45245)
VS Code sets `GIT_ASKPASS`, which simple-git rejects as unsafe unless
`allowUnsafeAskPass` is enabled, breaking the agent hooks when run from
a VS Code terminal.

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-12 13:00:59 +00:00
Sebastian Poxhofer 7436b80cda test(linter): add renovate/no-redundant-mock-reset rule (#44557)
ci(linter): add renovate/no-redundant-mock-reset rule

Vitest sets mockReset: true globally in vitest.config.mts, which resets
all mocks before each test. This makes vi.resetAllMocks() /
vi.clearAllMocks() and per-mock .mockReset() / .mockClear() calls inside
beforeEach/afterEach hooks redundant. Add a custom oxlint rule (enabled
for **/*.spec.ts and test/**) flagging such calls, and remove the 40
redundant calls it found. restoreAllMocks/mockRestore are not flagged
because restoreMocks is not enabled globally.

Two sites keep an inline disable with a reason: nested beforeEach hooks
in filter-checks.spec.ts and onboarding/pr/index.spec.ts intentionally
call mockReset() to discard once-values queued by an outer beforeEach.

Requested by maintainer review feedback (review comment 3052324877).

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-14 11:26:20 +00:00
Sebastian Poxhofer b632d27cdd ci(agents): extend AGENTS.md and add Claude hooks (#43470)
* ci: add agent instructions and ClaudeCode hooks

* refactor: rename start-check and use schemas

* fix: remove redundant flow diagram

* refactor: add block utility

* docs: add reference to development documentation

* ci: add pretooluse hook

* test: remove unnecessary schema tests

* ci: add --all flag run fixer and linters in a single command

* ci: switch stop hook to `pnpm check --all`

* refactor: use simple git

* refactor: use zod/v4

* ci: prevent usages of pnpm vitest

* ci: add must read and code example for codeBlock

* fixup! simplegit by allowing user pagers and editors

* ci(agent hooks): run installs on worktree changes

* docs: shorten description

* chore: remove additional new line at the end

* explicitly fail if parsing fails

* fix: rename to kebabcase

* docs: reduce commands highlighted for local dev
2026-06-08 13:56:15 +00:00