Browse Source

updated message

bugfixes
shitalp 10 years ago
parent
commit
be64473a39
  1. 69
      ee/cli/plugins/stack.py

69
ee/cli/plugins/stack.py

@ -70,9 +70,6 @@ class EEStackController(CementBaseController):
dict(help='Install Adminer stack', action='store_true')),
(['--utils'],
dict(help='Install Utils stack', action='store_true')),
(['--prompt'],
dict(help="ask permission for delete",
action='store_true')),
]
usage = "ee stack (command) [options]"
@ -1670,32 +1667,27 @@ class EEStackController(CementBaseController):
.format(EEVariables.ee_webroot)]
if len(apt_packages):
if self.app.pargs.prompt:
ee_apt_pkg_prompt = input('Are you sure you to want to'
' purge from server'
'. Package configuration will remain'
' on server after this operation.'
' Any answer other than '
' "yes" will be stop this'
' operation ')
else:
ee_apt_pkg_prompt = 'YES'
ee_apt_pkg_prompt = input('Are you sure you to want to'
' purge from server'
'. Package configuration will remain'
' on server after this operation.'
' Any answer other than '
' "yes" will be stop this'
' operation ')
if ee_apt_pkg_prompt == 'YES' or ee_apt_pkg_prompt == 'yes':
Log.debug(self, "Removing apt_packages")
Log.info(self, "Removing packages, please wait ...")
EEAptGet.remove(self, apt_packages)
EEAptGet.auto_remove(self)
if len(packages):
if self.app.pargs.prompt:
ee_pkg_prompt = input('Are you sure you to want to purge'
' from server.'
' Package configuration will remain '
'on server after this operation.'
' Any answer other than '
'"yes" will be stop this '
'operation ')
else:
ee_pkg_prompt = 'YES'
ee_pkg_prompt = input('Are you sure you to want to purge'
' from server.'
' Package configuration will remain '
'on server after this operation.'
' Any answer other than '
'"yes" will be stop this '
'operation ')
if ee_pkg_prompt == 'YES' or ee_pkg_prompt == 'yes':
EEFileUtils.remove(self, packages)
EEAptGet.auto_remove(self)
@ -1793,29 +1785,24 @@ class EEStackController(CementBaseController):
]
if len(apt_packages):
if not self.app.pargs.prompt:
ee_apt_pkg_prompt = input('Are you sure you to want to purge '
'from server '
'alongwith their configuration.'
' packages Any answer other than '
'"yes" will be stop this '
'operation ')
else:
ee_apt_pkg_prompt = 'YES'
ee_apt_pkg_prompt = input('Are you sure you to want to purge '
'from server '
'alongwith their configuration.'
' packages Any answer other than '
'"yes" will be stop this '
'operation ')
if ee_apt_pkg_prompt == 'YES' or ee_apt_pkg_prompt == 'yes':
Log.info(self, "Purging packages, please wait ...")
EEAptGet.remove(self, apt_packages, purge=True)
EEAptGet.auto_remove(self)
if len(packages):
if not self.app.pargs.prompt:
ee_pkg_prompt = input('Are you sure you to want to purge '
' from server alongwith '
' their configuration.'
' packages Any answer other than '
'"yes" will be stop this '
'operation ')
else:
ee_pkg_prompt = 'YES'
ee_pkg_prompt = input('Are you sure you to want to purge '
' from server alongwith '
' their configuration.'
' packages Any answer other than '
'"yes" will be stop this '
'operation ')
if ee_pkg_prompt == 'YES' or ee_pkg_prompt == 'yes':
EEFileUtils.remove(self, packages)
EEAptGet.auto_remove(self)

Loading…
Cancel
Save