From d551818ff0964ddb6e69c9a5a62504955f28d36c Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Sat, 15 Jul 2017 17:27:52 +0100 Subject: [PATCH] Support 256 colours in the terminal --- src/freedombone-utils-setup | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/freedombone-utils-setup b/src/freedombone-utils-setup index c01fd727..578aaf04 100755 --- a/src/freedombone-utils-setup +++ b/src/freedombone-utils-setup @@ -85,6 +85,18 @@ CHECK_MESSAGE="Check your internet connection, /etc/network/interfaces and /etc/ # Default diffie-hellman key length in bits DH_KEYLENGTH=2048 +function support_256_colours { + if ! grep 'xterm-256color' /etc/skel/.profile; then + echo '' >> /etc/skel/.profile + echo 'export TERM=xterm-256color' >> /etc/skel/.profile + fi + + if ! grep 'xterm-256color' /home/$MY_USERNAME/.profile; then + echo '' >> /home/$MY_USERNAME/.profile + echo 'export TERM=xterm-256color' >> /home/$MY_USERNAME/.profile + fi +} + function detect_usb_drive { # sets to the highest available drive letter # which is likely to be the last drive connected @@ -679,6 +691,9 @@ function setup_utils { function_check remove_management_engine_interface remove_management_engine_interface + function_check support_256_colours + support_256_colours + function_check enable_predictable_device_names enable_predictable_device_names