Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

close_project corrupts project workspace #6515

Open
Ben-Fields opened this issue Oct 17, 2024 · 0 comments
Open

close_project corrupts project workspace #6515

Ben-Fields opened this issue Oct 17, 2024 · 0 comments

Comments

@Ben-Fields
Copy link

Description of the bug

In trying to workaround #5701, I discovered that Sublime may remove the value of the "project": key in a project's *.sublime-workspace file. As a result, from the user's perspective, opening the project will not display the associated project folders in the side bar. Additionally, "Project>Edit Project" is greyed out, because there is no longer an association to the project file.

Steps to reproduce

  1. Open Sublime Text. Ensure the setting "hot_exit" is enabled.
  2. Open a project, MyProject.
  3. Close Sublime Text.
  4. Open Sublime Text with subl --command close_project
  5. Observe that the project's open folders disappear, but the open files of the project workspace remain.
  6. Re-opening the project by any method does not return its open folders.

Expected behavior

The project is closed, but may be re-opened later without issue.

Actual behavior

The project cannot be opened.

Sublime Text build number

4169

Operating system & version

Windows 10

(Linux) Desktop environment and/or window manager

No response

Additional information

To work around, either delete MyProject.sublime-workspace for a fresh workspace or:

  1. With "hot_exit" enabled, the saved state from "hot_exit" will overwrite the *.sublime-workspace file of any open project, so make sure you close the project before modifying its *.sublime-workspace file.
  2. Using a different editor, open MyProject.sublime-workspace and manually replace "project": "" with "project": "MyProject.sublime-project".

OpenGL context information

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants