diff options
author | Xi Ruoyao <xry111@xry111.site> | 2023-12-06 01:32:48 +0800 |
---|---|---|
committer | Xi Ruoyao <xry111@xry111.site> | 2023-12-06 01:32:48 +0800 |
commit | 31a9142d108a0fd32660068adc1c223a7e60e8b7 (patch) | |
tree | 5b2d5c4badd8395fca7d5e6558b9bdda64acbf81 /chapter10/kernel/kernel-config.py | |
parent | 981b9fa6a1a47b5ea93d899dc467be3649b0c253 (diff) |
kernel-config: Sync fixes from BLFS
Diffstat (limited to 'chapter10/kernel/kernel-config.py')
-rwxr-xr-x | chapter10/kernel/kernel-config.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/chapter10/kernel/kernel-config.py b/chapter10/kernel/kernel-config.py index a36113175..03e6ebb22 100755 --- a/chapter10/kernel/kernel-config.py +++ b/chapter10/kernel/kernel-config.py @@ -185,6 +185,10 @@ def load_kconfig(file): if_stack += [top] elif line.startswith('endif'): if_stack = if_stack[:-1] + + if config_buf: + r += [parse_config(config_buf)] + return r known_config = {} @@ -259,7 +263,7 @@ for i0, val, i1, title, arrow, key, menu, comment in r: if len(title) > rem: title = title[:rem - 3] + '...' - b = title.lstrip('YyMmNnHh') + b = title.lstrip('YyMmNnHh.' + "".join(map(str, range(10)))) a = title[:len(title) - len(b)] b0 = "<emphasis role='blue'>" + escape(b[0]) + "</emphasis>" line += escape(a) + b0 + escape(b[1:]) + escape(arrow) |