From f2017078f8fd3ce1f227a45482cf50edb4ff2d68 Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Sat, 13 Feb 2016 11:39:23 +0200 Subject: Add a try counter to do-until --- do-until | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/do-until b/do-until index c55f3d5..40a1911 100755 --- a/do-until +++ b/do-until @@ -60,9 +60,9 @@ class DoUntil(cliapp.Application): p.communicate() if p.returncode == 0: break - sys.stderr.write('do-until: command failed, ' + sys.stderr.write('do-until: attempt %d failed, ' 'trying again in %d second(s)\n' % - self.settings['sleep']) + (tries, self.settings['sleep'])) time.sleep(self.settings['sleep']) -- cgit v1.2.1