diff options
| author | Markus Heiser <markus.heiser@darmarit.de> | 2025-01-14 15:08:05 +0100 |
|---|---|---|
| committer | Markus Heiser <markus.heiser@darmarIT.de> | 2025-01-14 15:22:23 +0100 |
| commit | e4f8f0483f418da953724ddcbc3d67cfe6373ea9 (patch) | |
| tree | aff1f5d386e706a86b5fe224a09d177057b7d27f /utils/lib_sxng_themes.sh | |
| parent | 5a1a43ef74e29e6a4b41ee29cb0788d6bab606ce (diff) | |
[mod] slightly improve `make node.clean themes.all`
Signed-off-by: Markus Heiser <markus.heiser@darmarit.de>
Diffstat (limited to 'utils/lib_sxng_themes.sh')
| -rwxr-xr-x | utils/lib_sxng_themes.sh | 26 |
1 files changed, 19 insertions, 7 deletions
diff --git a/utils/lib_sxng_themes.sh b/utils/lib_sxng_themes.sh index 8d41b6480..a276dd8c5 100755 --- a/utils/lib_sxng_themes.sh +++ b/utils/lib_sxng_themes.sh @@ -9,16 +9,14 @@ themes.help(){ themes.: all : build all themes live : to get live builds of CSS & JS use 'LIVE_THEME=simple make run' - simple.: - build : build simple theme + simple.: build simple theme test : test simple theme + pygments: build pygment's LESS files for simple theme EOF } themes.all() { ( set -e - pygments.less - node.env themes.simple ) dump_return $? @@ -50,15 +48,29 @@ themes.live() { themes.simple() { ( set -e - build_msg GRUNT "theme: simple" - npm --prefix searx/static/themes/simple run build + node.env + themes.simple.pygments ) + build_msg GRUNT "theme: simple" + npm --prefix searx/static/themes/simple run build dump_return $? } +themes.simple.pygments() { + build_msg PYGMENTS "searxng_extra/update/update_pygments.py" + pyenv.cmd python searxng_extra/update/update_pygments.py \ + | prefix_stdout "${_Blue}PYGMENTS ${_creset} " + if [ "${PIPESTATUS[0]}" -ne "0" ]; then + build_msg PYGMENTS "building LESS files for pygments failed" + return 1 + fi + return 0 +} + + themes.simple.test() { build_msg TEST "theme: simple" - nodejs.ensure + node.env npm --prefix searx/static/themes/simple install npm --prefix searx/static/themes/simple run test dump_return $? |