WizardKit/setup/linux/profile/airootfs/etc/skel/.zlogin

36 lines
924 B
Bash

setterm -blank 0 -powerdown 0 2>/dev/null
if [ "$(fgconsole 2>/dev/null)" -eq "1" ]; then
# VM guest init
if lsmod | grep -Eq 'qxl|virtio_gpu'; then
systemctl start spice-vdagentd.service
fi
# Set up teststation details
$HOME/.setup_teststation
# Init Python
echo -n "Init Python modules..."
python -c "import wk"
echo "Done"
# Trust added root CAs
echo -n "Updating certificate store... "
sudo trust extract-compat
echo "Done"
# Start X or HW-diags
if ! grep -Fq "nox" /proc/cmdline; then
# Show freeze warning
echo ""
echo "NOTE: Not all GPUs/displays are supported."
echo " If the system is frozen on this screen"
echo " please restart and try CLI mode instead"
echo ""
# Start x
echo "Starting X..."
startx >/dev/null 2>&1
else
hw-diags --cli
fi
fi