hgkw/pretxnkw.py
branchextension
changeset 45 5acf520f2115
parent 44 dc6e7d0e607f
child 46 67e9fb23a32b
equal deleted inserted replaced
44:dc6e7d0e607f 45:5acf520f2115
    13         # bail out with error
    13         # bail out with error
    14         return True
    14         return True
    15 
    15 
    16     # reparse args, opts again as pretxncommit hook is silent about them
    16     # reparse args, opts again as pretxncommit hook is silent about them
    17     cmd, sysargs, globalopts, cmdopts = commands.parse(ui, sys.argv[1:])[1:]
    17     cmd, sysargs, globalopts, cmdopts = commands.parse(ui, sys.argv[1:])[1:]
    18     # exclude tagging
    18     # exclude tag and import
    19     if repr(cmd).split()[1] == 'tag':
    19     if repr(cmd).split()[1] in ('tag', 'import_'):
    20         return False
    20         return False
    21     files, match, anypats = cmdutil.matchpats(repo, sysargs, cmdopts)
    21     files, match, anypats = cmdutil.matchpats(repo, sysargs, cmdopts)
    22 
    22 
    23     # validity checks should have been done already
    23     # validity checks should have been done already
    24     modified, added = repo.status(files=files, match=match)[:2]
    24     modified, added = repo.status(files=files, match=match)[:2]