|
|
screen not working in 10.2.2
When I attempt to open screen from Terminal.app, I get the following error:
yet another startup script
I'm using bash under 10.2.2. In ~/.bash_profile, I've got:
exec screen
# include .bashrc if it exists
if [ -f ~/.bashrc ]; then
source ~/.bashrc
fi
In ~/.bashrc, I've got:
# If running interactively, then:
if [ "$PS1" ]; then
# set a fancy prompt
PS1='El Smeg:\w\$ '
# stuff for 'screen'
# Login greeting ------------------
if [ ! $SHOWED_SCREEN_MESSAGE ]; then
detached_screens=`screen -list | sed -n 's/^\(.*\)(Detached)$/|\1|/gp'`
if [ ! -z "$detached_screens" ]; then
echo "+---------------------------------------+"
echo "| Detached screens are available: |"
echo -n "$detached_screens"
echo
echo "+---------------------------------------+"
else
echo "+-----------------------------------------+"
echo "[ There are no detached screens available ]"
echo "+-----------------------------------------+"
fi
export SHOWED_SCREEN_MESSAGE="true"
fi
fi
In NetInfo Manager, I've got my shell set to /bin/bash (and using 'chsh').
The result of all of this is that when I open a new terminal window, it automatically starts 'screen' and shows me whether I've got any existing open sessions.
One last thing, supposedly you can use 'screen' to set the window title by the last command entered, but I can't get it to work properly. You can see more info searching 'man screen' for 'shelltitle'. I've got the following line in my ~/.bashrc:
# set a fancy prompt
PS1='El Smeg:\w\033k\033\134\$ '
|
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.06 seconds |
|