diff options
author | Curtis Dunham <Curtis.Dunham@arm.com> | 2016-04-28 15:18:52 +0100 |
---|---|---|
committer | Curtis Dunham <Curtis.Dunham@arm.com> | 2016-04-28 15:18:52 +0100 |
commit | 64dccbbf1bb019a400d098d7b3747eed52045ce8 (patch) | |
tree | 33c72521fd199da042f41ca161a65e134cccf44f | |
parent | 8be5717a02d7c50e4bacd8f86b7ac05f233b0ded (diff) | |
download | gem5-64dccbbf1bb019a400d098d7b3747eed52045ce8.tar.xz |
style: respect ignores for git commit
Previously it ignored the ignores for git but not Mercurial.
Change-Id: I178fe879ebd268e863063eb9e30ec87e8ac8faec
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
-rwxr-xr-x | util/git-pre-commit.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/util/git-pre-commit.py b/util/git-pre-commit.py index 33437faf3..353850846 100755 --- a/util/git-pre-commit.py +++ b/util/git-pre-commit.py @@ -42,7 +42,7 @@ import sys from style.repo import GitRepo from style.verifiers import all_verifiers, all_regions -from style.style import StdioUI +from style.style import StdioUI, check_ignores import argparse @@ -66,6 +66,8 @@ failing_files = set() for status, fname in git.status(filter="MA", cached=True): if args.verbose: print "Checking %s..." % fname + if check_ignores(fname): + continue if status == "M": regions = git.staged_regions(fname) else: |