build: add subcommands to kexttool
This commit is contained in:
@@ -1,10 +1,26 @@
|
||||
import yaml
|
||||
import io
|
||||
import os
|
||||
import glob
|
||||
|
||||
class KextSource:
|
||||
__kext_info = {}
|
||||
__src_dir_path = ''
|
||||
|
||||
|
||||
def scan(path):
|
||||
result = []
|
||||
scan_arg = os.path.join(path, '**/extension.yaml')
|
||||
|
||||
for filename in glob.iglob(scan_arg, recursive=True):
|
||||
try:
|
||||
kext_src = KextSource(filename)
|
||||
except Exception as e:
|
||||
continue
|
||||
|
||||
result.append(kext_src)
|
||||
|
||||
return result
|
||||
|
||||
|
||||
def __init__(self, info_file):
|
||||
|
||||
Reference in New Issue
Block a user