I was looking through the /etc/profile file and I noticed a strange if statement. Can someone let me know what this means?
I'm referring to the second if statement if [ "${-#*i}" != "$-"] .
for i in /etc/profile.d/*.sh /etc/profile.d/sh.local ; do
if [ -r "$i" ]; then
if [ "${-#*i}" != "$-" ]; then
. "$i"
else
. "$i" >/dev/null
fi
fi
done