treewide: Rename unmaintained to archived (MR 2308)

See https://gitlab.com/postmarketOS/pmaports/-/merge_requests/5046
This commit is contained in:
Newbyte 2024-05-06 23:12:04 +02:00 committed by Pablo Correa Gómez
parent d28174bf95
commit 0df75422b4
No known key found for this signature in database
GPG key ID: 7A342565FF635F79
5 changed files with 18 additions and 18 deletions

View file

@ -23,16 +23,16 @@ def find_path(args, codename, file=''):
return g[0]
def list_codenames(args, vendor=None, unmaintained=True):
def list_codenames(args, vendor=None, archived=True):
"""Get all devices, for which aports are available.
:param vendor: vendor name to choose devices from, or None for all vendors
:param unmaintained: include unmaintained devices
:param archived: include archived devices
:returns: ["first-device", "second-device", ...]
"""
ret = []
for path in glob.glob(args.aports + "/device/*/device-*"):
if not unmaintained and '/unmaintained/' in path:
if not archived and '/archived/' in path:
continue
device = os.path.basename(path).split("-", 1)[1]
if (vendor is None) or device.startswith(vendor + '-'):