From 3c42645cdffc81ac4edaa942ec28fd99a5142189 Mon Sep 17 00:00:00 2001 From: Avery Pennarun Date: Sat, 13 Nov 2010 01:45:16 -0800 Subject: [PATCH] Given a directory name as a target, try building dirname/all. ...if dirname/all.do exists. This is a convenient command-line shortcut. --- redo.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/redo.py b/redo.py index fa73af3..f1c3097 100755 --- a/redo.py +++ b/redo.py @@ -121,6 +121,9 @@ if not vars.DEPTH: retcode = 0 startdir = os.getcwd() for t in targets: + if os.path.exists('%s/all.do' % t): + # t is a directory, but it has a default target + t = '%s/all' % t mkdirp('%s/.redo' % vars.BASE) os.chdir(startdir) try: