I work on a company project using the VSCode extension Language Support for Java (TM) by Red Hat. My team uses a Maven profile called ide-build
for local development skipping the Angular build (which itself is done by the running Angular watcher). This profile is important, because without it, the Maven build includes the complete Angular build which takes 20+ seconds each time a file changes.
This profile is set in the project's .settings/org.eclipse.m2e.core.prefs
file. However, every time the Java Language Server is cleaned via "Java: Clean Java Language Server Workspace", the profile gets removed for...inexplicable reasons:
What I have tried:
org.eclipse.m2e.core.prefs
file). Unfortunately, this is overwritten by the Red Hat extension when cleaning the Java Language Server..vscode/settings.json
via "maven.executable.options": "-Pide-build"
. Regrettably, according to this GitHub issue, vscode-java ignores this setting.If our project had only 1 or 2 of these settings files, it would still be bearable to have to manually set the active profile each time, but we have 51 total. So we are looking for a way to persist these settings without the extension silently undoing them.