Skip to content

[APP] Development > Visual Studio Code cleanup overly broad #286

@adidalal

Description

@adidalal

Thanks for developing this app!

Based on the code, it looks like the two paths looked at for vscode are:

~/Library/Application Support/Code/
~/.vscode/extensions/

There are extremely broad - if you delete the former, it'll reset the entire application (including deleting user settings and signing you out, and if you delete the latter, it resets installed extensions.

A more targeted (and inline with the name of the tab) approach would be to cleanup the specific cache folders. Those are:

~/Library/Application Support/Code/Cache
~/Library/Application Support/Code/CachedConfigurations
~/Library/Application Support/Code/CachedData
~/Library/Application Support/Code/CachedExtensionVSIXs
~/Library/Application Support/Code/CachedExtensions
~/Library/Application Support/Code/CachedProfilesData
~/Library/Application Support/Code/Code Cache

There's also a workspaceStorage folder, and it's safe to delete invalid references there - vscode-workspace-storage-cleanup and this gist have implementations

I'm happy to submit a pull request to update the paths, but I'm not a Swift developer and I'm not sure the best way to implement the invalid workspaceStorage cleanup feature.

References:

microsoft/vscode#32461
microsoft/vscode#3884

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions