We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7bd5b86 commit 64eb60bCopy full SHA for 64eb60b
tools/update-dbus-docs.py
@@ -31,6 +31,10 @@ class NoCommand(Exception):
31
'org.freedesktop.DBus.Introspectable',
32
'org.freedesktop.DBus.Properties',
33
]
34
+RED = '\x1b[31m'
35
+GREEN = '\x1b[32m'
36
+YELLOW = '\x1b[33m'
37
+RESET = '\x1b[39m'
38
39
def xml_parser():
40
return etree.XMLParser(no_network=True,
@@ -327,7 +331,8 @@ def parse_args():
327
331
c = classification if info['modified'] else ''
328
332
if c:
329
333
modified.append(page)
330
- print(f'{p:{mlen + 1}} {t - m}/{t} {c}')
334
+ color = RED if m > t/2 else (YELLOW if m else GREEN)
335
+ print(f'{color}{p:{mlen + 1}} {t - m}/{t} {c}{RESET}')
336
337
if opts.test and modified:
338
exit(f'Outdated pages: {", ".join(modified)}\n'
0 commit comments