How do I add external tools to eclipse project context menu? - eclipse

I have a few commands that I've defined as "External Tools" in eclipse. I would like to run said commands against one or more projects. Right now, I have to click on the project in package explorer, move my mouse to the 'Run' menu, move down to External Tools, and then click on the tool I want to run.
Ideally I would like to do this from the right click context menu in "Package Explorer". That is I'd like to right click on the project, select "external tools" and then select the command I want. How do I customize eclipse to do this?
I tried looking around "Customize Perspective..." menu, but couldn't find anything that would help.

Related

Eclipse (STS) Open Resource "Show In" menu

When using STS 3.7.1.RELEASE (on Windows, based on Eclipse Mars.1 4.5.1), I'd like to navigate to a file using "Open Resource" dialog and show the file in Package or Project Explorer using the "Show In" button.
But the Show In menu only shows "Terminal" and no "Project Explorer" option. Why is that and how can I fix it? Are there any options to be configured to get it working?
4 years later, that has been fixed with Eclipse 2019-09:
The Show In context menu is now available for an element inside a resource project on the Project Explorer.

Config eclipse preferences in project explorer

Can I config somewhere which options there are when I make a right click in the project explorer and there is the extended menu of "new" and change for example "new php project" to "new php file"? Thanks for yout answers
You can configure the top level of the 'File > New' menu using 'Window > Perspective > Customize Perspective' dialog (or just 'Window > Customize Perspective' before Eclipse Mars).
Choose the 'Shortcuts' tab and configure the items you want to appear.
The items that are available in that submenu is based on the context, on whatever you have selected when you right-click. For example, if you right-click on an existing PHP project, then you should see an option to create a new PHP file in that project.
Keep in mind that Eclipse is fundamentally project-based; you can't really create files outside of a project.

pydev plugin in eclipse not showing the files in the project explorer

I am using pydev plugin in eclipse. I can create the project, but I cannot see the files in the project explorer.
I am attaching the screenshot. Any idea how to fix it.
Thanks
Kiran
in Pydev explorer Ctrl+F10 then from Top Level Elements choose Projects. It will show the projects in your workspace
I got a little workaround. I'm not sure what the difference between "PyDev Package Explorer" and "Package Explorer" is supposed to be, but it's clear that one of them is buggy.
I'm well aware that this is from 2011, but I came across this question while searching for it. I hope my answer will help someone.
Ensure you are in the "PyDev" perspective.
Top menu bar > Window > Customize Perspective...
Menu Visibility tab
Under "Edit", tick the "Show views" box (it might be half-ticked somehow depending on how your OS displays that). Press OK.
Top menu bar > Window > Show view > Package Explorer
A new 'view' should now be visible, called "Package Explorer". Move Package Explorer to an appropriate space (click and drag).
Delete the old "PyDev Package Explorer".
It seems that Eclipse does not have the resources up to date...
Have you configured Eclipse to do automatic refresh of resources?
Preferences > General > Startup and Shutdown: check 'Refresh workspace on startup'
Preferences > Workspace: check: Refresh automatically (this depends on your Eclipse version -- in 3.7 the settings were changed a bit, but it should be easy to know which configurations are related).
You can also try making a manual refresh: either F5 or right-click: refresh.
Another thing to check is if the path of the project is actually the path you're expecting (i.e.: the path that has the resources) -- you can press Alt+Enter to open the properties for the project and check if the location is actually correct.

How to prevent Eclipse from showing the opened file in package explorer

somehow I've ended up in a situation such that when I navigate through source files with Eclipse, the Eclipse always selects (and expands) the opened file with package explorer. With this I end up
losing my location on Package Explorer
Having my Package explorer expanded and pretty confusing.
With brief googling/exploring on the preferences I couldn't find this one..
Eclipse version is 3.4 if that happens to matter.
Thanks in advance,
Touko
Turn off the "Link with Editor" option in the Package Explorer toolbar.
(the left/right arrow icon, turned on here)
Select a source file, right click on it, choose "Open with" and then "Java Editor". The Java Editor should be the default after that for all java files.

Execute external file from Eclipse PDT?

I would like to add button to toolbar or menu item to menu in Eclipse PDT to run external command line exe or bat file. How to do this in Windows?
You can create a custom "External Tools" run configuration.
Click on the button beside the Run button which looks the same as the Run button except it has a little red toolbox. Choose "External Tools Configurations" and create a new "Program" run configuration.