Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Is zsh buggy in connection with screen?
- X-seq: zsh-users 9674
- From: Ian Langworth <ian.langworth@xxxxxxxxx>
- To: Wayne Davison <wayned@xxxxxxxxxxxxxxxxxxxxx>
- Subject: Re: Is zsh buggy in connection with screen?
- Date: Tue, 8 Nov 2005 17:09:42 -0500
- Cc: zsh-users@xxxxxxxxxx
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=UxBk8FDZG9SXdWrjl+uzqkOAKRJEtMog/J+R9VjnFv7eHxPkRS1tZdAOdvYUOQwXp+F4YUMUGSf/ILes27s17hDjvqcZ5FB+1sRGv7gTX6mZZNTgRrvccosW5EZ3fSgtPNUVG0zkw7ZqBM8S+NuWLf0hGeIxbK6SSzkh4z9GOwI=
- In-reply-to: <20051108174411.GH24349@xxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <20051108130233.GA6146@xxxxxxxx> <20051108141317.GQ27583@xxxxxxxxxxxxx> <20051108174411.GH24349@xxxxxxxxxxxxx>
I have a similar problem with ssh-agent. New screen windows
automatically get the updated environment when I've shelled freshly
into the machine, but existing shells in windows need to run
"latestssh."
# the problem with screen is that old sessions lose ssh-agent awareness. this
# little system fixes it.
local agentdir=~/.latestssh
local agentfile=$agentdir/$HOST.sh
mkdir -p $agentdir
chmod 0700 $agentdir >/dev/null
if [ -n "$SSH_AUTH_SOCK" -a -z $STY ]; then
echo "export SSH_AUTH_SOCK=$SSH_AUTH_SOCK" >$agentfile
chmod 0600 $agentfile >/dev/null
fi
# ...existing windows can run this alias
alias latestssh="source $agentfile; ls \$SSH_AUTH_SOCK"
# ...new windows get it automatically
if [ -n "$STY" ]; then
source $agentfile
fi
--
Ian Langworth
Messages sorted by:
Reverse Date,
Date,
Thread,
Author