Skip to content

try-repo does not work with builtin #1521

@George-Ogden

Description

@George-Ogden

Summary

I wanted to test the builtin hook.

prek try-repo builtin check-merge-conflict -a

should run the check-merge-conflict on all files, but instead:

error: Failed to determine repository and revision
  caused by: Command `get head rev` exited with an error:

[status]
exit status: 128

[stderr]
fatal: 'builtin' does not appear to be a git repository
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.

I'm a big fan of the repo - it's great to see a better alternative of the original pre-commit!

Platform

linux (Debian)

Version

prek 0.3.1

.pre-commit-config.yaml

N/A

Log file

2026-02-01T13:08:03.169951Z DEBUG prek: 0.3.1
2026-02-01T13:08:03.169975Z DEBUG Args: ["prek", "try-repo", "builtin", "check-merge-conflict", "--directory", "tests/merge-conflict"]
2026-02-01T13:08:03.170067Z TRACE Executing /usr/bin/git ls-remote --exit-code builtin HEAD

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions