shell: modify profile warning

This commit is contained in:
PowerUser64 2022-09-18 03:31:30 -07:00
parent d2ed902127
commit dd1ba90cbf

View file

@ -38,7 +38,8 @@ error() {
# change cursor to a beam by default
printf '\e[5 q'
if ! "${PROFILE_LOADED:-false}"; then
# Warn if profile isn't loaded, if not in an ssh connection
if ! "${PROFILE_LOADED:-false}" || [ -z "${SSH_TTY:+foo}" ]; then
echo "Warning: profile was not loaded! Set PROFILE_LOADED to 'true' to disable this warning." >&2
fi