Skip to content

Commit 0ea3046

Browse files
authored
IEP-1543 Set the default setCompilationDatabase to false (#1233)
* feat: setCompilationDatabase default to false
1 parent 198d8d5 commit 0ea3046

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

bundles/com.espressif.idf.lsp/src/com/espressif/idf/lsp/preferences/IDFClangdMetadataDefaults.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ public class IDFClangdMetadataDefaults extends ConfigurationMetadataBase impleme
2222
@Override
2323
protected List<PreferenceMetadata<?>> definePreferences()
2424
{
25-
Set<String> filteredKeys = Set.of(Predefined.clangdPath.identifer(), Predefined.queryDriver.identifer());
25+
Set<String> filteredKeys = Set.of(Predefined.clangdPath.identifer(), Predefined.queryDriver.identifer(),
26+
Predefined.setCompilationDatabase.identifer());
2627

2728
var filteredDefaults = Predefined.defaults.stream().filter(pref -> filteredKeys.contains(pref.identifer()))
2829
.toList();
@@ -38,10 +39,12 @@ protected List<PreferenceMetadata<?>> definePreferences()
3839

3940
var queryDriverMetadataWithDefault = wrapWithCustomDefaultValue(defaultIdfQueryDriver,
4041
ClangdMetadata.Predefined.queryDriver);
42+
var setCompilationDatabaseDefault = wrapWithCustomDefaultValue(false, Predefined.setCompilationDatabase);
4143

4244
List<PreferenceMetadata<?>> mergedPreferences = new ArrayList<>(filteredDefaults);
4345
mergedPreferences.add(clangdMetadataWithDefault);
4446
mergedPreferences.add(queryDriverMetadataWithDefault);
47+
mergedPreferences.add(setCompilationDatabaseDefault);
4548

4649
return mergedPreferences;
4750
}

0 commit comments

Comments
 (0)