A few months ago, RStudio file explorer started showing a different directory upon startup. I was wondering if anyone knew how this could be changed back to how it was before. I work primarily on 1 project, I user a project file and I need the root of the project to stay where it is.
Here is an example of the directory structure:
Dir1
|---Dir2
|---Dir3 (root as defined by project file)
|--- subDir1
|--- subDir2
|--- subDir3
At startup, file explorer used to be in subDir2, now it is always in subDir3.
Maybe the project saves in a way the last path opened in File Explorer.
Did you try navigating back to the correct folder then closing the project and reopening ? In that case, is the subdir3 path also restored whereas you had set it back to Dir3 just before closing ?
I just tried myself and I can confirm that the last open path in file explorer is restored when you open. RStudio saves the state of the IDE to be restored afterward.You can easily get back to your project root dir by clicking on the blue box in the File pane
That was my first thought, too, and I have tried what you suggested before but the problem persists. But I always work in subdir2 and hardly open subdir3, which is why it surprised me that it suddenly now always opens up in subdir3. This happened "over night" so to speak, without me making any changes, and now I cannot get rid of it.