Skip to content

Session working directory is being incorrectly restored #336

Open
@rinfiyks

Description

@rinfiyks

Steps to reproduce:

  1. Start a new session.
  2. cd into a different directory.
  3. If you open a new window in that session, the working directory for that window will be your home directory, not the directory you just changed to in the first window. This is expected tmux behaviour, because you never changed the session working directory.
  4. Using tmux-resurrect, save, kill, and restore tmux.
  5. The session working directory will now be the directory you changed into in step 2, even though you never changed it. So if you open a new window, the behaviour will now be different to what it was in step 3: its PWD will be the directory you changed to in step 2.

I always want my session working directory to by ~. Every time I restore tmux, for each session, it sets the session working directory to be the directory of the first window in that session, so I have to go around running :a -c ~ in each affected session to set it back to ~.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions