flatpak-vscode
flatpak-vscode copied to clipboard
Diff to `.vscode/settings.json`
I commit .vscode/settings.json
to git repo. Sometimes, I get a diff, where the order of settings.json
is edited for mesonbuild
properties. First, I thought writing to the workspace configuration when the property is not changed was the problem, but #227 didn't fix my problem.
After some debugging, I found that changing the flatpak manifest causes the VSCode window to reload. This means the meson and rust integrations are first unloaded and then loaded. This causes the workspace config to be set to undefined
and later to the same value.
This leads me to two question:
- Why is the VSCode window reloaded on every manifest save? (I have auto-save enabled, so for me this is every keystroke)
- Why is the workspace configuration removed on unloading the integration?
Why is the VSCode window reloaded on every manifest save? (I have auto-save enabled, so for me this is every keystroke)
If i remember correctly, meson extension causes the window to reload as its config changes.
Why is the workspace configuration removed on unloading the integration?
I suppose it makes the configuration obsolete when the integration is unloaded, but I see it being a problem when the config is set by the user.
I think we should not re-write the settings every time the user changes anything in the manifest. That would require a smarter diff between the two buffers to figure out whether:
- The dependencies/sdk changed, force an update deps/build deps first
- The app-id/finish-args/sdk changed, update extensions integrations settings