Add SFC alias to bash_aliases at firstrun

because 14 extra characters is too much.
This commit is contained in:
Tom 2025-02-09 00:30:16 +00:00 • committed by GitHub
parent 1ee196aaa6
commit 9799a4709f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -96,8 +96,16 @@ else
echo "TERM, LANG and NCURSES_NO_UTF8_ACS already present in .bashrc, skipping"
fi
# Add a cheeky alias to .bash_aliases
if ! grep -Fxq "alias sfc='sudo femto-config'" /home/femto/.bash_aliases; then # Check if the lines are already in .bash_aliases
echo "alias sfc='sudo femto-config'" >> /home/femto/.bash_aliases
echo "alias sfc='sudo femto-config' to .bash_aliases"
else
echo "alias sfc='sudo femto-config' already present in .bash_aliases, skipping"
fi
# remove first boot flag
sed -i -E 's/^first_boot=.*/first_boot=false/' /etc/femto.conf
log_message "Removing first boot flag and rebooting in 5 seconds..."
sleep 5
reboot
reboot