pmb.parse._apkbuild: parse provider_priority as int (MR 2132)
This commit is contained in:
parent
19b232969d
commit
47645f41b1
|
@ -559,6 +559,7 @@ apkbuild_package_attributes = {
|
|||
"pkgdesc": {},
|
||||
"depends": {"array": True},
|
||||
"provides": {"array": True},
|
||||
"provider_priority": {"int": True},
|
||||
"install": {"array": True},
|
||||
|
||||
# UI meta-packages can specify apps in "_pmb_recommends" to be explicitly
|
||||
|
|
|
@ -209,6 +209,11 @@ def _parse_attributes(path, lines, apkbuild_attributes, ret):
|
|||
if options.get("array", False):
|
||||
# Split up arrays, delete empty strings inside the list
|
||||
ret[attribute] = list(filter(None, ret[attribute].split(" ")))
|
||||
if options.get("int", False):
|
||||
if ret[attribute]:
|
||||
ret[attribute] = int(ret[attribute])
|
||||
else:
|
||||
ret[attribute] = 0
|
||||
|
||||
|
||||
def _parse_subpackage(path, lines, apkbuild, subpackages, subpkg):
|
||||
|
|
Loading…
Reference in New Issue