I have the exact opposite Problem of this question: Visual Studio Code always reopens previous file or folder
VSCode never seems to remembery my previously opened files and does always start with an empty window. I checked, if my Shortcut has the Parameter "-n" by accident (which would force this behaviour), but it's not there.
Is there a way to force VSCode to remember opened files and folders?
For more control over Auto Save , open User or Workspace settings and find the associated settings: files. autoSave : Can have the values: off - to disable auto save.
In Visual Studio 2020 you can use Shift + Ctrl + T , which is associated with Reopen Closed Editor. This should do what you're expecting. You are speaking of VS Code. In VS Code the default is: { "key": "ctrl+shift+t", "command": "workbench.
It seems, VsCode only remembers opened files, if you also have a folder opened. It doesn't matter, if this is just a Dummy Folder somewhere on your drive - if you open files outside of this folder, they will be remembered aswell.
I'm not sure if this is as designed, or a bug.
Edit: This is a bug and tracked here
Edit 2: To sum up the answers from below there are now two settings concerning this issue:
Hot exit has been implemented, which restores files which weren't saved before VS Code is closed. To change this, use this setting:
files.hotExit: "onExit"
To reopen all files, use this setting:
window.restoreWindows: "all"
But there is still on open issue with this found here.
...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With