#!/usr/bin/env bash # SPDX-License-Identifier: AGPL-3.0-or-later declare _Blue declare _creset themes.help(){ cat <&1 \ | prefix_stdout "${_Blue}THEME ${1} ${_creset} " \ | grep -E --ignore-case --color 'error[s]?[:]? |warning[s]?[:]? |' } themes.simple() { ( set -e build_msg GRUNT "theme: simple" npm --prefix searx/static/themes/simple run build ) dump_return $? } themes.marlo() { ( set -e build_msg GRUNT "theme: marlo" npm --prefix searx/static/themes/marlo run build ) dump_return $? } themes.simple.test() { build_msg TEST "theme: simple" nodejs.ensure npm --prefix searx/static/themes/simple install npm --prefix searx/static/themes/simple run test dump_return $? } themes.marlo.test() { build_msg TEST "theme: marlo" nodejs.ensure npm --prefix searx/static/themes/marlo install npm --prefix searx/static/themes/marlo run test dump_return $? }