Compare commits
1 Commits
master
...
feature/de
Author | SHA1 | Date |
---|---|---|
Oliver Smith | ba95043c9c |
|
@ -249,6 +249,15 @@ def parse_apkindex(args):
|
|||
raise RuntimeError("Package not found in the APKINDEX: " +
|
||||
args.package)
|
||||
result = result[args.package]
|
||||
|
||||
# Filter --depends
|
||||
if args.depends:
|
||||
result_new = {}
|
||||
for pkgname, package in result.items():
|
||||
if args.depends in package["depends"]:
|
||||
result_new[pkgname] = package
|
||||
result = result_new
|
||||
|
||||
print(json.dumps(result, indent=4))
|
||||
|
||||
|
||||
|
|
|
@ -314,6 +314,9 @@ def arguments():
|
|||
parse_apkindex = sub.add_parser("parse_apkindex")
|
||||
parse_apkindex.add_argument("apkindex_path")
|
||||
parse_apkindex.add_argument("package", default=None, nargs="?")
|
||||
parse_apkindex.add_argument("--depends", default=None, help="only list"
|
||||
" packages depending on a specific package"
|
||||
" (e.g. so:libstdc++.so.6)")
|
||||
|
||||
# Action: config
|
||||
config = sub.add_parser("config",
|
||||
|
|
Loading…
Reference in New Issue