Kaydet (Commit) eb017c9e authored tarafından Suleyman Poyraz's avatar Suleyman Poyraz

Daha nazik ve şık çıktılar

Nazik ve birazcık daha okunabilir çıktılar.
üst 0618c676
......@@ -554,7 +554,7 @@ class Install(AtomicOperation):
inary.db.installdb.InstallDB().mark_needs_reboot(package_name)
# filesdb
ctx.ui.info(_('Adding files of \"{}\" package to db...').format(self.metadata.package.name), color='brightpurple')
ctx.ui.info(_('Adding files of \"{}\" package to database...').format(self.metadata.package.name), color='brightpurple')
ctx.filesdb.add_files(self.metadata.package.name, self.files)
# installed packages
......@@ -716,11 +716,12 @@ class Remove(AtomicOperation):
self.historydb.add_and_update(pkgBefore=self.package, operation="remove")
def remove_inary_files(self):
ctx.ui.info(_('Removing files of \"{}\" package from system').format(self.package_name), color='faintpurple')
util.clean_dir(self.package.pkg_dir())
def remove_db(self):
self.installdb.remove_package(self.package_name)
ctx.ui.info(_('Removing files of \"{}\" package from database...').format(self.package_name), color='faintyellow')
self.installdb.remove_package(self.package_name)
ctx.filesdb.remove_files(self.files.list)
......
......@@ -212,7 +212,7 @@ class CLI(inary.ui.UI):
color = 'brightgreen'
elif event == inary.ui.removing:
msg = _('Removing \"{}\"').format(keywords['package'].name)
color = 'faintpurple'
color = 'brightpurple'
elif event == inary.ui.upgraded:
msg = _('Upgraded \"{}\"').format(keywords['package'].name)
color = 'brightgreen'
......
......@@ -71,7 +71,7 @@ NB: We support only local files (e.g., /a/b/c) and http:// URIs at the moment
if ctx.ui.confirm(_('Add \"{}\" repository without updating the database?\nBy confirming '
'this you are also adding the repository to your system without '
'checking the distribution of the repository.\n'
'Do you want to continue?').format(name)):
'Would you like to continue?').format(name)):
self.just_add=True
if indexuri.endswith(".xml.xz") or indexuri.endswith(".xml"):
......
......@@ -265,7 +265,7 @@ class File:
if ret:
ctx.ui.info("Checking GPG Signature failed ('gpg --verify {}')".format(sigfilename), color='cyan')
ctx.ui.info(err.decode("utf-8"), color='faintcyan')
if not ctx.ui.confirm("Would you like skip checking gpg signature?"):
if not ctx.ui.confirm("Would you like to skip checking gpg signature?"):
raise InvalidSignature(uri) # everything is all right here
def flush(self):
......
......@@ -68,7 +68,7 @@ installed in the respective order to satisfy dependencies:
return
if len(order_inst) + len(order_build) > len(A_0):
if not ctx.ui.confirm(_('There are extra packages due to dependencies. Do you want to continue?')):
if not ctx.ui.confirm(_('There are extra packages due to dependencies. Would you like to continue?')):
return False
ctx.ui.notify(ui.packagestogo, order=order_inst)
......
......@@ -204,7 +204,7 @@ def takeback(operation):
if beremoved:
ctx.ui.info(_("Following packages will be removed:\n") + util.strlist(beremoved))
if (beremoved or beinstalled) and not ctx.ui.confirm(_('Do you want to continue?')):
if (beremoved or beinstalled) and not ctx.ui.confirm(_('Would you like to continue?')):
return
errors = []
......@@ -218,7 +218,7 @@ def takeback(operation):
if errors:
ctx.ui.info(_("\nFollowing packages could not be found in repositories and are not cached:\n") +
util.strlist(errors))
if not ctx.ui.confirm(_('Do you want to continue?')):
if not ctx.ui.confirm(_('Would you like to continue?')):
return
if beremoved:
......
......@@ -81,7 +81,7 @@ def install_pkg_names(A, reinstall=False, extra=False):
extra_packages = set(order) - A_0
if extra_packages:
if not ctx.ui.confirm(_('There are extra packages due to dependencies. Do you want to continue?')):
if not ctx.ui.confirm(_('There are extra packages due to dependencies. Would you like to continue?')):
return False
ctx.ui.notify(ui.packagestogo, order=order)
......@@ -212,7 +212,7 @@ def install_pkg_files(package_URIs, reinstall=False):
ctx.ui.warning(_("The following packages will be installed "
"in order to satisfy dependencies:"))
ctx.ui.info(util.format_by_columns(sorted(extra_packages)))
if not ctx.ui.confirm(_('Do you want to continue?')):
if not ctx.ui.confirm(_('Would you like to continue?')):
raise Exception(_('External dependencies not satisfied'))
install_pkg_names(extra_packages, reinstall=True, extra=True)
......
......@@ -80,7 +80,7 @@ def remove(A, ignore_dep=False, ignore_safety=False):
in the respective order to satisfy dependencies:"""), color='green')
ctx.ui.info(util.strlist(order))
if len(order) > len(A_0):
if not ctx.ui.confirm(_('Would you like to continue??')):
if not ctx.ui.confirm(_('Would you like to continue?')):
ctx.ui.warning(_('Package removal declined'))
return False
......
......@@ -206,7 +206,7 @@ def upgrade(A=None, repo=None):
return
if needs_confirm and \
not ctx.ui.confirm(_("Do you want to continue?")):
not ctx.ui.confirm(_("Would you like to continue?")):
return False
ctx.ui.notify(ui.packagestogo, order=order)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment