Gnu Screen workflow management (change working directory)

I was recently asked how to change screens working directory. It took me a few minutes to realize the benefit of this as I typically have different screen sessions for different purposes. But after thinking about it for a few minutes I have been in situations where what I was doing in a screen session morphed and it would have been nice for new windows to be opened to a different working directory than where I started my session.

A few minutes of grepping around in man -a screen gave the answer.

C-a:chdir /path/to/new/dir


  • Thanks for posting this – and for showing up first for “gnu screen change session directory” ๐Ÿ™‚
    I’ve wanted to know this since about 2008 and now I finally now ๐Ÿ™‚

  • Glad you found it useful ๐Ÿ™‚ I don’t even remember my use case for this any-more but I do remember thinking it was a handy trick.

Leave a Reply

Your email is never shared.Required fields are marked *

To submit your comment, click the image below where it asks you to...
Clickcha - The One-Click Captcha