mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
OMG we're running a hook
This commit is contained in:
parent
47bad120e4
commit
871ab4d72f
11 changed files with 105 additions and 25 deletions
24
pre_commit/languages/all.py
Normal file
24
pre_commit/languages/all.py
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
|
||||
from pre_commit.languages import node
|
||||
from pre_commit.languages import python
|
||||
from pre_commit.languages import ruby
|
||||
|
||||
# A language implements the following two functions in its module:
|
||||
#
|
||||
# def install_environment():
|
||||
# """Installs a repository in the given repository. Note that the current
|
||||
# working directory will already be inside the repository.
|
||||
# """
|
||||
#
|
||||
# def run_hook(hook, file_args):
|
||||
# """Runs a hook and returns the returncode and output of running that hook.
|
||||
#
|
||||
# Returns:
|
||||
# (returncode, stdout, stderr)
|
||||
# """
|
||||
|
||||
languages = {
|
||||
'node': node,
|
||||
'python': python,
|
||||
'ruby': ruby,
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue