mirror of
https://github.com/overleaf/toolkit.git
synced 2025-04-19 15:28:06 +02:00
refactor section separators
This commit is contained in:
parent
fe0b336523
commit
dc4451d434
1 changed files with 5 additions and 8 deletions
13
bin/doctor
13
bin/doctor
|
@ -17,11 +17,8 @@ function indent_to_level() {
|
|||
echo -n "${spaces}"
|
||||
}
|
||||
|
||||
function print_doctor_header() {
|
||||
echo "== Overleaf Doctor =="
|
||||
}
|
||||
function print_doctor_footer() {
|
||||
echo "== End =="
|
||||
function print_section_separator() {
|
||||
echo "== $* =="
|
||||
}
|
||||
|
||||
function print_heading() {
|
||||
|
@ -118,7 +115,7 @@ function check_docker_daemon() {
|
|||
|
||||
function print_warnings() {
|
||||
if [[ -n "$(head -n 1 $WARNINGS_FILE)" ]]; then
|
||||
echo "== Warnings =="
|
||||
print_section_separator "Warnings"
|
||||
while read -r _line; do
|
||||
echo "! $_line"
|
||||
done < "$WARNINGS_FILE"
|
||||
|
@ -130,12 +127,12 @@ function cleanup() {
|
|||
}
|
||||
|
||||
function __main__() {
|
||||
print_doctor_header
|
||||
print_section_separator "Overleaf Doctor"
|
||||
check_host_information
|
||||
check_dependencies
|
||||
check_docker_daemon
|
||||
print_warnings
|
||||
print_doctor_footer
|
||||
print_section_separator "End"
|
||||
cleanup
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue