diff options
author | Ali Saidi <saidi@eecs.umich.edu> | 2009-01-13 00:14:04 -0500 |
---|---|---|
committer | Ali Saidi <saidi@eecs.umich.edu> | 2009-01-13 00:14:04 -0500 |
commit | 758d6ccf1f54ca20bec12598957fc1bcfa8a7ffb (patch) | |
tree | ddec768306420132ac9253080ba72aac30ece59b | |
parent | 81180a3bf005586d7ca1fae77dd7888b99e45864 (diff) | |
download | gem5-758d6ccf1f54ca20bec12598957fc1bcfa8a7ffb.tar.xz |
Fix style hook for Mercurial >= 1.1
-rw-r--r-- | util/style.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/util/style.py b/util/style.py index a117fab70..fa9a30b54 100644 --- a/util/style.py +++ b/util/style.py @@ -304,7 +304,12 @@ def do_check_whitespace(ui, repo, *files, **args): if prompt(fname): return True - wctx = repo.workingctx() + try: + wctx = repo.workingctx() + except: + from mercurial import context + wctx = context.workingctx(repo) + for fname in modified: if skip(fname): continue |