Public bug reported:

OS version: Linux Mint 20.2 Cinnamon
Cinnamon version: 5.0.7

There are several missed quote paires in /etc/profile and wrong operator
used. So this config should be fixed as follows:

# /etc/profile: system-wide .profile file for the Bourne shell (sh(1))
# and Bourne compatible shells (bash(1), ksh(1), ash(1), ...).

if [ "${PS1-}" ]; then
  if [ "${BASH-}" ] && [ "$BASH" != "/bin/sh" ]; then
    # The file bash.bashrc already sets the default PS1.
    # PS1='\h:\w\$ '
    if [ -r /etc/bash.bashrc ]; then # -f replaced with -r
      . /etc/bash.bashrc
    fi
  else
    if [ "`id -u`" -eq 0 ]; then
      PS1='# '
    else
      PS1='$ '
    fi
  fi
fi

if [ -d /etc/profile.d ]; then
  for i in /etc/profile.d/*.sh; do
    if [ -r "$i" ]; then # Missed quotes added
      . "$i" # Missed quotes added
    fi
  done
  unset i
fi

** Affects: ubuntu
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1952895

Title:
  Some mistakes in /etc/profile

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+bug/1952895/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to