shorter outcome printing
This commit is contained in:
parent
34a6276b20
commit
7dc70982e5
41
urchin
41
urchin
|
@ -378,36 +378,29 @@ format_urchin() {
|
||||||
currentdir="$(dirname -- "${path}")"
|
currentdir="$(dirname -- "${path}")"
|
||||||
prevdir="${currentdir}"
|
prevdir="${currentdir}"
|
||||||
|
|
||||||
|
if test -z "${the_shell}"; then
|
||||||
|
message="${the_shell} on ${remote} is not executable."
|
||||||
|
else
|
||||||
|
unit="$(plural second "${file_elapsed}")"
|
||||||
|
message="${the_shell} on ${remote} (${file_elapsed} ${unit})"
|
||||||
|
fi
|
||||||
case "${result}" in
|
case "${result}" in
|
||||||
ok)
|
ok) if "${print_ok}"; then
|
||||||
if "${print_ok}"; then
|
header && echo "${success_mark} ${message}"
|
||||||
header
|
fi ;;
|
||||||
printf "${success_mark} "
|
not_ok) if "${print_not_ok}"; then
|
||||||
echo "${the_shell} ("${file_elapsed}" $(plural second $file_elapsed))"
|
header && echo "${fail_mark} ${message}"
|
||||||
fi
|
fi ;;
|
||||||
;;
|
skip) if "${print_ok}"; then
|
||||||
not_ok)
|
header && echo "${skip_mark} ${message}"
|
||||||
if "${print_not_ok}"; then
|
fi ;;
|
||||||
header
|
|
||||||
printf "${fail_mark} "
|
|
||||||
echo "${the_shell} ("${file_elapsed}" $(plural second $file_elapsed))"
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
skip)
|
|
||||||
if "${print_ok}"; then
|
|
||||||
header
|
|
||||||
if test -z "${the_shell}"; then
|
|
||||||
echo ' (Specified shell is not executable.)'
|
|
||||||
else
|
|
||||||
echo " ${the_shell} ("${file_elapsed}" $(plural second $file_elapsed))"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if { test "${result}" = not_ok && "${print_not_ok_stdout}"; } ||
|
if { test "${result}" = not_ok && "${print_not_ok_stdout}"; } ||
|
||||||
{ test "${result}" = ok && "${print_ok_stdout}"; }; then
|
{ test "${result}" = ok && "${print_ok_stdout}"; }; then
|
||||||
sed 's/^/ | /' "$(stdout_file "${path}" "${the_shell}")"
|
sed 's/^/ | /' "$(stdout_file "${path}" "${the_shell}")"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
prevpath="${path}"
|
prevpath="${path}"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue