comps-sync.py: remove deplicate func def & fixup comment

This commit is contained in:
Timothée Ravier 2018-08-07 20:56:47 +02:00
parent 194a8da4fb
commit 78432354e3
1 changed files with 1 additions and 9 deletions

View File

@ -160,21 +160,13 @@ for desktop in [ 'gnome-desktop', 'kde-desktop', 'xfce-desktop' ]:
print(' ' + pkg)
manifest_packages.remove(pkg)
# Look for packages in workstation but not in the manifest
# Look for packages in comps but not in the manifest
ws_added = set()
for pkg in ws_pkgs:
if pkg not in manifest_packages:
ws_added.add(pkg)
manifest_packages.add(pkg)
def format_pkgtype(n):
if n == libcomps.PACKAGE_TYPE_DEFAULT:
return 'default'
elif n == libcomps.PACKAGE_TYPE_MANDATORY:
return 'mandatory'
else:
assert False
n_comps_new = len(ws_added)
if n_comps_new == 0:
print("All comps packages are already listed in manifest.")