I wrote a plugin which contributes a com.intellij.configurationType. In the UI I bring up the Run/Debug Configurations editor and click + to create a new one. I select my configuration and the editor creates a new config of my type called “Unnamed.”
Is it possible for me to get this editor to use a name I suggest when creating?
From Run Configurations | IntelliJ Platform Plugin SDK
ConfigurationFactory
classes are responsible for creating run configuration instances. The only method required to be implemented is createTemplateConfiguration()
, which is called once for each project to create the run configuration template.
for dynamic naming:
To support the automatic naming of configurations created from context, the configuration should extend LocatableConfigurationBase
. It supports generating a name for a configuration from its settings and tracking whether the user changed the name.
Thank you for the response. For future readers this is what I found.
My class already extends ModuleBasedConfiguration
so I can’t literally follow the advice from the documentation. But I did find that the interface LocatableConfiguration
is implemented so I could override String suggestedName().