1
0
mirror of https://gitlab.com/ceda_ei/wish synced 2025-05-12 00:46:57 +02:00
wish/plugins/exit_code.sh
2019-02-16 23:01:30 +05:30

21 lines
429 B
Bash

function wish_exit_code_start() {
return 0
}
function wish_exit_code_end() {
return 0
}
function wish_exit_code_set_colors() {
WISH_EXIT_CODE_FG=${WISH_EXIT_CODE_FG:-$WISH_DEFAULT_FG}
WISH_EXIT_CODE_BG=${WISH_EXIT_CODE_BG:-$WISH_DEFAULT_BG}
}
function wish_exit_code_main() {
if [[ $1 == 0 ]]; then
wish_append $WISH_EXIT_CODE_BG $WISH_EXIT_CODE_FG ""
else
wish_append $WISH_EXIT_CODE_BG $WISH_EXIT_CODE_FG $1
fi
}