. lib/copy_dirtrees_of_tags
. lib/core_setup
. lib/expect_n_args
+. lib/prefixed_msg
. lib/put_finished_marker
+prefixed_msg_init
+
PATH_NETWORK_INTERFACES="${PATH_ETC}/network/interfaces"
THINKPAD_NAMES="x220 w530 t490s"
WLAN_SSID=$(get_network_interfaces_last_wpa_value 'ssid')
WLAN_PSK=$(get_network_interfaces_last_wpa_value 'psk')
if [ ! -z "${WLAN_SSID}" ]; then
- echo "Found, adding to NetworkManager."
+ prefixed_msg "Found, adding to NetworkManager."
if [ -z "${WLAN_PSK}" ]; then
nmcli connection add type wifi wifi.ssid "${WLAN_SSID}"
else # NB: assumes last (collected with tail -1) wpa-psk that of last wlan-ssid
# NB: This needs to come before steps potentially overwriting /etc/network/interfaces.
apt-get -y install network-manager > /dev/null
if [ "$(nmcli -f TYPE conn | grep 'wifi' | wc -l)" = "0" ]; then
- echo "\n# Checking for existing wifi config in ${PATH_NETWORK_INTERFACES} …"
+ prefixed_msg "Checking for existing wifi config in ${PATH_NETWORK_INTERFACES} …"
adopt_wifi_connection
else
- echo "\n# Already know wifi connection, nothing to add …"
+ prefixed_msg 'Already know wifi connection, nothing to add …'
fi
core_setup "${SYSTEM_NAME}" "" "" "${INSTALL_TAGS}"
-echo '\n# Ensuring our desired locale is available …'
+prefixed_msg 'Ensuring our desired locale is available …'
locale-gen
-echo '\n# Final user setup …'
+prefixed_msg 'Final user setup …'
adduser --quiet "${USERNAME}" plugdev # so user may use pmount
echo "${USERNAME}:${USER_PW}" | chpasswd
put_finished_marker 'setup_desktop'
+prefixed_msg_exit