update install.sh

This commit is contained in:
Егор 2024-11-10 11:15:06 +00:00
parent 5968d5a12b
commit d73b2827b1

View File

@ -145,8 +145,11 @@ EXPORT_MESSSAGE="export $MESSAGE"
if [ ! "$(id -u)" -ne 0 ] if [ ! "$(id -u)" -ne 0 ]
then then
print_msg "Add path to profile"
echo $MESSAGE >> /etc/profile echo $MESSAGE >> /etc/profile
sudo mkdir -p /etc/kos32-gcc
echo $TOOLCHAIN_DIR > /etc/kos32-gcc/install-path
else else
if ! grep -q $EXPORT_MESSSAGE ~/.bashrc; then if ! grep -q $EXPORT_MESSSAGE ~/.bashrc; then
print_msg "Adding '$TOOLCHAIN_DIR/win32/bin' to '~/.bashrc'" print_msg "Adding '$TOOLCHAIN_DIR/win32/bin' to '~/.bashrc'"
@ -154,13 +157,10 @@ else
fi fi
fi fi
# WTF?!
sudo /usr/bin/mkdir -p /etc/kos32-gcc
echo $TOOLCHAIN_DIR | sudo tee /etc/kos32-gcc/install-path
export $MESSAGE export $MESSAGE
cd "$OLDPWD" cd "$OLDPWD"
print_ok "Installation was successful!" print_ok "Installation was successful!"