2019-07-24 05:33:28 +00:00
|
|
|
#!/bin/zsh
|
2019-02-18 16:55:05 +00:00
|
|
|
# deal with screen, if we're using it - courtesy MacOSXHints.com
|
|
|
|
# Login greeting ------------------
|
2019-07-24 05:33:28 +00:00
|
|
|
if [ "$TERM" = "screen" ] && [ ! "$SHOWED_SCREEN_MESSAGE" = "true" ]; then
|
2019-02-18 16:55:05 +00:00
|
|
|
detached_screens=$(screen -list | grep Detached)
|
2019-07-24 05:33:28 +00:00
|
|
|
if [ -n "$detached_screens" ]; then
|
2019-02-18 16:55:05 +00:00
|
|
|
echo "+---------------------------------------+"
|
|
|
|
echo "| Detached screens are available: |"
|
|
|
|
echo "$detached_screens"
|
|
|
|
echo "+---------------------------------------+"
|
|
|
|
fi
|
2019-07-24 05:33:28 +00:00
|
|
|
fi
|