mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-07 00:39:09 -06:00
Add identity meta hook
This commit is contained in:
@@ -237,6 +237,7 @@ class MetaRepository(LocalRepository):
|
||||
# The hooks are imported here to prevent circular imports.
|
||||
from pre_commit.meta_hooks import check_hooks_apply
|
||||
from pre_commit.meta_hooks import check_useless_excludes
|
||||
from pre_commit.meta_hooks import identity
|
||||
|
||||
def _make_entry(mod):
|
||||
"""the hook `entry` is passed through `shlex.split()` by the
|
||||
@@ -260,6 +261,13 @@ class MetaRepository(LocalRepository):
|
||||
'language': 'system',
|
||||
'entry': _make_entry(check_useless_excludes),
|
||||
},
|
||||
{
|
||||
'id': 'identity',
|
||||
'name': 'identity',
|
||||
'language': 'system',
|
||||
'verbose': True,
|
||||
'entry': _make_entry(identity),
|
||||
},
|
||||
]
|
||||
|
||||
return {
|
||||
|
||||
Reference in New Issue
Block a user