hledger/tools/coverage

11 lines
346 B
Python

#!/usr/bin/env python
# usage: hledger$ tools/coverage HPCCOMMAND HLEDGERARGS
# A front-end for hledgercov/hpc. Resets the tix count on each invocation.
import sys, os
cov="hledgercov"
cmd, args = sys.argv[1], ' '.join(sys.argv[2:])
os.system("rm -f %s.tix" % cov)
os.system("./%s %s >/dev/null" % (cov,args))
os.system("hpc %s %s" % (cmd,cov))