diff options
author | Markus Heiser <markus.heiser@darmarit.de> | 2021-04-26 19:06:30 +0200 |
---|---|---|
committer | Markus Heiser <markus.heiser@darmarit.de> | 2021-04-26 19:09:40 +0200 |
commit | ec10ba7fcb7b11e93b3f682cb2d45cd6dafd7b94 (patch) | |
tree | 895001fe59a63b3043fdce5de449064788a7bc04 /searx_extra | |
parent | 3cf97774dab5b1f4b1aeb2d32284567c4b18abbf (diff) | |
download | searxng-ec10ba7fcb7b11e93b3f682cb2d45cd6dafd7b94.tar.gz searxng-ec10ba7fcb7b11e93b3f682cb2d45cd6dafd7b94.zip |
[mod] update_pygments -- prompt filenames of updated files
BTW: remove trailing whitespace
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'searx_extra')
-rwxr-xr-x | searx_extra/update/update_pygments.py | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/searx_extra/update/update_pygments.py b/searx_extra/update/update_pygments.py index 067cd4594..bdf03227e 100755 --- a/searx_extra/update/update_pygments.py +++ b/searx_extra/update/update_pygments.py @@ -92,7 +92,7 @@ RULE_CODE_LINENOS = """ .linenos { -ms-user-select: none; user-select: none; cursor: default; - + &::selection { background: transparent; /* WebKit/Blink Browsers */ } @@ -111,7 +111,7 @@ def get_output_filename(relative_name): def get_css(cssclass, style): result = f"""/* - this file is generated automatically by searx_extra/update/update_pygments.py + this file is generated automatically by searx_extra/update/update_pygments.py using pygments version {pygments.__version__} */\n\n""" css_text = HtmlFormatter(style=style).get_style_defs(cssclass) @@ -124,13 +124,20 @@ def get_css(cssclass, style): def main(): - with open(get_output_filename('static/themes/oscar/src/less/logicodev/pygments.less'), 'w') as f: + + fname = 'static/themes/oscar/src/less/logicodev/pygments.less' + print("update: %s" % fname) + with open(get_output_filename(fname), 'w') as f: f.write(get_css(CSSCLASS, LogicodevStyle)) - with open(get_output_filename('static/themes/oscar/src/less/pointhi/pygments.less'), 'w') as f: + fname = 'static/themes/oscar/src/less/pointhi/pygments.less' + print("update: %s" % fname) + with open(get_output_filename(fname), 'w') as f: f.write(get_css(CSSCLASS, 'default')) - with open(get_output_filename('static/themes/simple/less/pygments.less'), 'w') as f: + fname = 'static/themes/simple/less/pygments.less' + print("update: %s" % fname) + with open(get_output_filename(fname), 'w') as f: f.write(get_css(CSSCLASS, 'default')) |