Handle KeyboardInterrupt with less annoying spew to stderr.
This commit is contained in:
parent
9c349cf652
commit
3de384497d
3 changed files with 38 additions and 29 deletions
|
|
@ -48,12 +48,15 @@ if not vars.TARGET:
|
|||
err('redo-ifchange: error: must be run from inside a .do\n')
|
||||
sys.exit(100)
|
||||
|
||||
want_build = []
|
||||
for t in sys.argv[1:]:
|
||||
mkdirp('%s/.redo' % vars.BASE)
|
||||
add_dep(vars.TARGET, 'm', t)
|
||||
if dirty_deps(t, depth = ''):
|
||||
want_build.append(t)
|
||||
try:
|
||||
want_build = []
|
||||
for t in sys.argv[1:]:
|
||||
mkdirp('%s/.redo' % vars.BASE)
|
||||
add_dep(vars.TARGET, 'm', t)
|
||||
if dirty_deps(t, depth = ''):
|
||||
want_build.append(t)
|
||||
|
||||
if want_build:
|
||||
os.execvp('redo', ['redo', '--'] + want_build)
|
||||
if want_build:
|
||||
os.execvp('redo', ['redo', '--'] + want_build)
|
||||
except KeyboardInterrupt:
|
||||
sys.exit(200)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue