* fix: ctx.ui.info is not smart like print
* fix: make the package lists into sets in the high-level package ops
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE Project SYSTEM "Project-3.8.dtd">
|
||||
<!-- Project file for project pisi -->
|
||||
<!-- Saved: 2005-10-09, 20:14:24 -->
|
||||
<!-- Saved: 2005-10-09, 23:29:35 -->
|
||||
<!-- Copyright (C) 2005 PiSi Development Team, -->
|
||||
<Project version="3.8">
|
||||
<ProgLanguage mixed="0">Python</ProgLanguage>
|
||||
@@ -348,6 +348,10 @@
|
||||
<Dir>tools</Dir>
|
||||
<Name>ChangeLogGenerator.py</Name>
|
||||
</Source>
|
||||
<Source>
|
||||
<Dir>pisi</Dir>
|
||||
<Name>oo.py</Name>
|
||||
</Source>
|
||||
</Sources>
|
||||
<Forms>
|
||||
</Forms>
|
||||
@@ -385,10 +389,10 @@
|
||||
<VcsOtherData>{'standardLayout': 1}</VcsOtherData>
|
||||
</Vcs>
|
||||
<FiletypeAssociations>
|
||||
<FiletypeAssociation pattern="*.ui.h" type="FORMS" />
|
||||
<FiletypeAssociation pattern="*.ui" type="FORMS" />
|
||||
<FiletypeAssociation pattern="*.idl" type="INTERFACES" />
|
||||
<FiletypeAssociation pattern="*.ptl" type="SOURCES" />
|
||||
<FiletypeAssociation pattern="*.py" type="SOURCES" />
|
||||
<FiletypeAssociation pattern="*.ui.h" type="FORMS" />
|
||||
<FiletypeAssociation pattern="*.idl" type="INTERFACES" />
|
||||
<FiletypeAssociation pattern="*.ui" type="FORMS" />
|
||||
<FiletypeAssociation pattern="*.ptl" type="SOURCES" />
|
||||
</FiletypeAssociations>
|
||||
</Project>
|
||||
|
||||
+4
-2
@@ -213,6 +213,8 @@ def install_pkg_names(A):
|
||||
the repository, trying to perform a minimum number of
|
||||
installs"""
|
||||
|
||||
A = set(A) # A was a list, remove duplicates
|
||||
|
||||
ctx.ui.debug('A = %s' % str(A))
|
||||
|
||||
if len(A)==0:
|
||||
@@ -324,7 +326,7 @@ def upgrade_pkg_names(A):
|
||||
ctx.ui.info(_('Package %s is already at its latest version %s,\
|
||||
release %s, build %s.')
|
||||
% (x, pkg.version, pkg.release, pkg.build))
|
||||
A = Ap
|
||||
A = set(Ap)
|
||||
|
||||
if len(A)==0:
|
||||
ctx.ui.info(_('No packages to upgrade.'))
|
||||
@@ -407,7 +409,7 @@ def remove(A):
|
||||
Ap.append(x)
|
||||
else:
|
||||
ctx.ui.info(_('Package %s does not exist. Cannot remove.') % x)
|
||||
A = Ap
|
||||
A = set(Ap)
|
||||
|
||||
if len(A)==0:
|
||||
ctx.ui.info(_('No packages to remove.'))
|
||||
|
||||
@@ -545,8 +545,8 @@ Usage: list-installed
|
||||
package = pisi.packagedb.inst_packagedb.get_package(pkg)
|
||||
inst_info = ctx.installdb.get_info(pkg)
|
||||
if self.options.long:
|
||||
ctx.ui.info(package)
|
||||
ctx.ui.info(inst_info)
|
||||
ctx.ui.info(str(package))
|
||||
ctx.ui.info(str(inst_info))
|
||||
elif self.options.install_info:
|
||||
ctx.ui.info('%-15s | %s ' % (package.name, inst_info.one_liner()))
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user