screen-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Get current working directory from another screen window


From: Jostein Berntsen
Subject: Re: Get current working directory from another screen window
Date: Fri, 24 Jun 2011 00:05:14 +0200
User-agent: Mutt/1.5.20 (2009-06-14)

On 23.06.11,14:25, Sadrul Habib Chowdhury wrote:
> On Wed, Jun 22, 2011 at 10:38 AM, Tomasz Muras <address@hidden> wrote:
> > Hello,
> >
> > I'm wondering if something like this would be possible:
> > I would like to quickly switch to the same current working directory
> > as in another screen window. Would it be possible to read cwd of
> > another window?
> 
> The windows in screen are unaware of each other. So what you want to
> do cannot be done through screen [easily].
> 

If you know the specific windows numbers and have xclip available, you 
can use something like this command:

eval "at '4' stuff 'echo `pwd` | xclip -sel clip\n'" eval "at '2' \ 
stuff 'cd `xclip -sel clip -o`\n'"

Windows 2 will then cd to the same directory as in window 4.


Jostein






reply via email to

[Prev in Thread] Current Thread [Next in Thread]