mirror of
https://github.com/pre-commit/pre-commit-hooks.git
synced 2026-04-05 11:36:54 +00:00
more fixes for syntax checking
This commit is contained in:
parent
97448dfed7
commit
44c6676070
1 changed files with 2 additions and 2 deletions
|
|
@ -3,12 +3,12 @@ from __future__ import print_function
|
|||
import argparse
|
||||
import sys
|
||||
|
||||
import util
|
||||
from pre_commit_hooks.util import cmd_output
|
||||
|
||||
|
||||
def is_on_branch(protected):
|
||||
retval = False
|
||||
branch = util.cmd_output('git', 'symbolic-ref', 'HEAD')
|
||||
branch = cmd_output('git', 'symbolic-ref', 'HEAD')
|
||||
chunks = branch.strip().split('/')
|
||||
if chunks[2] == protected:
|
||||
retval = True
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue