I don\'t know how, but my STS has got duplicate toolbars items and I am not sure how to remove them. Here is how my duplicated toolbar looks like.
I want to
I've been having the same problem since upgrading to Oxygen. I haven't been able to reliably reproduce the issue.
The workaround suggested by @howlger has helped and is less intrusive than blowing away the entire workspace:
.metadata\.plugins\org.eclipse.e4.workbench\workbench.xmi
file or just rename it so you can bring it back in case you need to revert.This is a pain, but does remove the duplicate elements from toolbars.
I also found that customizing the perspective doesn't work for duplicated items, but does for non-duplicated:
Not an actual answer, more additional info that I hope will help track down the problem. I am having the same issue with Version: 2018-12 (4.10.0), Build: 20181214-0600.
I opened the workbench.xmi file mentioned above. This was the section I found by searching for "Open a Terminal", which is the tooltip on a repeated icon.
<children xsi:type="menu:ToolBar" xmi:id="_tODFlzriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.toolbar">
<tags>Draggable</tags>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFmDriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFmTriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFmjriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFmzriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFnDriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFnTriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFnjriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_tODFnzriEem5AdcasuU54g" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_tOOFADriEem5AdcasuU54g">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
</children>
When I refreshed workbench.xmi I found this (two icons appear):
<children xsi:type="menu:ToolBar" xmi:id="_FzpBgzrrEemLeYohrjtX4w" elementId="org.eclipse.tm.terminal.view.ui.toolbar">
<tags>Draggable</tags>
<children xsi:type="menu:HandledToolItem" xmi:id="_FzpBhDrrEemLeYohrjtX4w" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_Fzw9IzrrEemLeYohrjtX4w">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
<children xsi:type="menu:HandledToolItem" xmi:id="_FzpBhTrrEemLeYohrjtX4w" elementId="org.eclipse.tm.terminal.view.ui.commands.launchToolbar"
iconURI="platform:/plugin/org.eclipse.tm.terminal.view.ui/icons/eview16/console_view.png" tooltip="Open a Terminal" command="_Fzw9IzrrEemLeYohrjtX4w">
<persistedState key="IIdentifier" value="org.eclipse.tm.terminal.view.ui/org.eclipse.tm.terminal.view.ui.commands.launchToolbar"/>
</children>
</children>
I notice, also, that the ids have been updated.
John
This appears to be an issue in the core Eclipse platform. While the screenshot shows pretty icons thanks to Darkest Dark, it does not appear related at this time to Darkest Dark plugin as Howlger has indicated. Instead, it appears that duplicate contribution entries appear in the workbench.xmi file. In our testing (I contribute to Darkest Dark), we can see these entries happening in a standalone Eclipse, though haven't been able to track down the root cause yet in where entries get added again to the workbench.xmi.
Interestingly, a user has posted on an old Eclipse bug with what looks like a screenshot of Eclipse Classic exhibiting the same problem today.
https://bugs.eclipse.org/bugs/show_bug.cgi?id=402561
Screenshot from Eclipse Bug
I can't say why this happened in the first place, but I do know how to get rid of the duplicate entries. We've experienced the same problem on our Eclipse based product.
Window > New Window
Close the old window and be free of the duplicate actions weighing you down.
It looks like you have installed the Darkest Dark Theme plug-in. Try to uninstall it.
This closed source plug-in does load-time weaving to patch Java bytecode of the Eclipse platform (for legal reasons, to not have to publish their changes). In contrast of using a public API, load-time weaving patches have to be adapted for each (new) Eclipse version: an error in the plug-in can cause strange behavior of the Eclipse platform.
See also: Keyboard shortcuts in Eclipse Oxygen stopped working