summaryrefslogtreecommitdiff
path: root/shellutils.py
diff options
context:
space:
mode:
authorSylvain Th?nault <sylvain.thenault@logilab.fr>2010-09-24 14:44:16 +0200
committerSylvain Th?nault <sylvain.thenault@logilab.fr>2010-09-24 14:44:16 +0200
commit2c6b07b2740b1d23617aa103e108e016766b6186 (patch)
tree1869c280aa98b60ce9c02594738c766a1da53f0b /shellutils.py
parentb8d45493069b9374d7b354189abd63f96c49a966 (diff)
downloadlogilab-common-2c6b07b2740b1d23617aa103e108e016766b6186.tar.gz
py2.3 compat : import compat.set, remove deprecated stuff
Diffstat (limited to 'shellutils.py')
-rw-r--r--shellutils.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/shellutils.py b/shellutils.py
index 4c6e8a8..8e3cc3e 100644
--- a/shellutils.py
+++ b/shellutils.py
@@ -339,13 +339,6 @@ class ProgressBar(object):
self._last_text_write_size = len(text.rstrip())
self._stream.flush()
-from logilab.common.deprecation import deprecated
-
-@deprecated('confirm() is deprecated, use RawInput.confirm() instead')
-def confirm(question, default_is_yes=True):
- """ask for confirmation and return true on positive answer"""
- return RawInput().confirm(question, default_is_yes)
-
class RawInput(object):
@@ -365,7 +358,7 @@ class RawInput(object):
label += '(%s)' % option[1:].lower()
choices.append((option, label))
prompt = "%s [%s]: " % (question,
- '/'.join(opt[1] for opt in choices))
+ '/'.join([opt[1] for opt in choices]))
tries = 3
while tries > 0:
answer = self._input(prompt).strip().lower()