39 lines
1.1 KiB
Bash
39 lines
1.1 KiB
Bash
|
#!/usr/bin/env bash
|
||
|
# Copyright (C) 2024 Adrien 'neox' Bourmault <neox@gnu.org>
|
||
|
#
|
||
|
# This program is free software: you can redistribute it and/or modify
|
||
|
# it under the terms of the GNU General Public License as published by
|
||
|
# the Free Software Foundation, either version 3 of the License, or
|
||
|
# (at your option) any later version.
|
||
|
#
|
||
|
# This program is distributed in the hope that it will be useful,
|
||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
|
# GNU General Public License for more details.
|
||
|
#
|
||
|
# You should have received a copy of the GNU General Public License
|
||
|
# along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||
|
|
||
|
## Some variables
|
||
|
greyblue='\033[38;5;245m'
|
||
|
color_reset='\033[0m'
|
||
|
|
||
|
. includes.sh
|
||
|
|
||
|
## Main program ---------------------------------------------------------------
|
||
|
main()
|
||
|
{
|
||
|
stop_logs
|
||
|
exit 0
|
||
|
echo -e ${color_reset}
|
||
|
boot
|
||
|
wait_for_expression "Debian GNU/Linux 9"
|
||
|
echo System successfully booted!
|
||
|
wait_for_expression "link becomes ready"
|
||
|
wait_for_expression "ttyS1"
|
||
|
echo SSH should be ready
|
||
|
shutdown
|
||
|
echo Successful power cycle!
|
||
|
}
|
||
|
main
|