What is the runtime-EclipseApplication folder for, and can I delete it safely? - eclipse

I'm trying to organise the directory structure of my projects' source code and the eclipse workspace etc.
I found a folder called runtime-EclipseApplication in a high level folder outside the directories where I keep my workspace and projects.
What is this folder, when/why is it created and is it safe to delete?

This is the default for the workspace name when you use Run As > Eclipse Application.
You can look in the Eclipse Applications section of the Run > Run Configurations dialog to see what (if anything) is using this workspace. The workspace name is shown in the Location field of the Main tab.

Related

What is difference between Project Path and Workspace in spring Tool suite?

There's an option to start a project in Spring Tool Suite we can select our Project path and Workspace. Where I need to choose if I need to save project files?
I need to save files on D:\3rd year\SQA location. Where I need to put this, in Project path or Workspace?
Updated
In this window when I click "Add a local project" link in below the above window appear.
The workspace is a concept of Eclipse and contains the metadata for settings and which projects belong to the workspace. You can put your projects into your workspace folder, but you don't have to. You can put your projects anywhere you like. And you can import projects from anywhere into your workspace.
When creating new projects in Eclipse/STS, the wizard usually asks you where to store the project itself. The default is often set to the workspace location, but you can change that and put the project anywhere.
Therefore, in your example, the project path is probably the path where your project itself is stored (or will be stored), whereas the workspace location is the location where your workspace metadata information will be stored.
Hope this helps!

what should keep in mind before providing work space for eclipse?

This is how the workspace assign on an eclipse
My Web project run only when my project is at c:\Ampps\www\myProject but eclipse contains it on C:\Simple\workspace\myProject. My problem is I want to run project and the workspace is different. What is the things keep in mind before choosing the workspace. And what are the alternatives if the wrong workspace choosen ?
Eclipse does not require your projects to live under your workspace folder. Therefore you are allowed to have a project and workspace as you describe.
When creating a project, uncheck the default location checkbox in the wizard and select your truly desired location.
My only recommendation on workspace location is to have it on a local drive and don't have it as a sub directory of any project in your workspace.

eclipse workspace: how to rename workspace

There is no option in the file menu to rename a workspace. Is the recommended practice to close eclipse, rename the folder, and re-open? I worry about some potential dangling references in configuration files corrupting my workspace/projects...
Thanks!
Source : Renaming a workspace?
Yes, you can just rename the workspace
directory and/or move it. However, you
then have to tell Eclipse where the
new workspace is. In 3.1, you can use
'switch workspace' to launch in a
different location (under the File
menu).
If you want to change it by hand, you
can edit the appropriate entries in
the files in the 'configuration'
directory where Eclipse is stored.
You can change the
org.eclipse.ui.ide.prefs file to set
SHOW_WORKSPACE_SELECTION_DIALOG=true
if you want to be asked each time
Eclipse is run where the workspace is.
For simple renaming, it is not necessary to switch workspaces, unless the workspace you want to rename is not the one currently active.
Anyway, you can rename the current open workspace by choosing Eclipse->Preferences->General->Workspace and changing the option "Workspace name (shown in window title)" from the default's workspace folder name to whatever you want to call it. Then, restart Eclipse.
Suppose your workspace's folder is "/foo/bar/workspace" and you never changed its name before; its name was then the default "workspace". After you renamed it to, say, "my_workspace" and restarted Eclipse, the Eclipse's window title should show: "my_workspace - (some stuff that varies) - /foo/bar/workspace".
Note that this is NOT going to modify the workspace folder's name. You may have to create a new folder with the desired name, switch to that folder (whose workspace will have the same name, by default) and import existing projects into it, as some have suggested here.
Renaming Workspace folder worked for me. Close the eclipse, rename the workspace folder name, launch eclipse again. If you are using any project dependencies like user libraries,launchers etc, you have to relocate those to new location manually, from project build path.
Copying workspace to a new folder works. Any reference Eclipse itself needs is resolved using the relative workspace location. If you have added launchers, substitution variables, etc. that rely on the absolute workspace location, they will need to be reset.
John,
I think in the original workspace you imported projects and that the projects depend on links not on being physically in the same location of the worspace (even thay are there already but the dependency is on links). If so you have to remove the projects from the new (copied) worspace and then re-import them again.
I just did a:
File --> Import --> Maven --> Existing Maven Projects --> mention the new workspace location in "Root Directory" in the "Import Maven Projects" window
and it worked! All projects were imported properly.
BTW, I have Eclipse-Maven plugin "m2e" installed (http://wiki.eclipse.org/M2E_updatesite_and_gittags)
2021 Update
In Eclipse 2020-12 (Windows 10), the "Workspace name (shown in window title)" preference mentioned in one answer is no longer there. Now, renaming a workspace (WS) requires a copy and delete operation.
Start by switch to another WS: File --> Switch Workspace --> select existing WS. Then rename the WS folder to desired new name. Switch to the new workspace folder and delete the old name:
File --> Switch Workspace --> Other...
Right-click old WS name --> Remove from launcher selection
Click Browse --> select new workspace folder --> click Launch and Voila!
As mentioned in prior posts, depending on your setup some resource links may be broken. Delete the project without(!) removing it from disk, then import to new WS.

How do I associate my custom ANT builder with the project instead of the Eclipse workspace?

I'd like to associate some ANT targets with my project's build in Eclipse.
No problem, I create a custom ANT builder, specify targets to run, all is well.
But then I realize that the builder information is saved in the workspace instead of the project! Why is that, and how do I fix it?
The goal is that anyone who imports the project in a new Eclipse workspace can build it without adding the builder manually. This means that I should have the builder configuration under source control, which means it should belong to the project, not the per-user workspace.
Maybe I'm just missing something?
There is a bit of confusion, it seems, because builders look like launchers, but they are stored in a different directory. Simply creating the .settings dir and copying the xml doesn't help...
When I create the .externalToolBuilders directory under .settings and copy the launcher/builder there, I get this:
Solution:
I restarted from scratch, deleted the project-specific data in the workspace directory, but left the .settings dir in the project dir. Re-created the builder/launcher, and Eclipse automatically created it in the correct place, and also added it to source control.
Indeed, your launcher (Run/Debug launchers or External Builders launchers) are saved by default in the workspace.
<workspace>\myProject\.externalToolsBuilder)
You can move that directory (.externalToolsBuilder) manually in the .settings directory of your project.
And uncheck the option "Delete configurations when associated resource is deleted" as mentioned in this SO answer.
With a full refresh of the project (or even a delete, followed by a reimport), your local version of .externalToolsBuilder should be taken into account.
For the Debug/Run launchers (not your case), you also can (since Eclipse3.4) use one of the Import wizards:
File > Import
type launch configuration, and you can import said configuration directly within your project.

Eclipse - Ignore Entire Directories

I use Aptana Studio (based on Eclipse). I'm trying to get Eclipse to completely ignore an entire directory inside a project. I mean COMPLETELY. I don't want it to display in the project folder. I don't want Eclipse to even be aware it exists.
Unfortunately, all my efforts to add it as a filter don't work. See http://forums.aptana.com/viewtopic.php?f=14&t=8340#p33714 . I think the filter only prevents the folder from being displayed in the project display. It doesn't keep Eclipse from actually looking at all the files in that folder for code assist, etc.
My problem is that directory has thousands of text files. So, each time Eclipse opens or refreshes this project, it analyzes all those files.
How can I prevent this?
Not sure about this aptana thing, but there is a convenient way to do it in native eclipse:
Right-click a project folder in Project Explorer tree and go to "Properties".
Resource -> Resource Filters.
Add as much exclusion filters for files/folders as you like.
If your project tree is not refreshed immediately, press F5 to enforce it.
Consider also the 'Derived' checkbox: right-click an entry in the package explorer, choose properties, check Derived. This may solve part of your problem.
See http://robmayhew.com/eclipse-ignore-folder/
If you have a linked resource (pointing off to some other file/folder on disk) with the same name in the same location in the resource tree, then the real folder on disk will be hidden from the resource model.
Unfortunately you can't create the linked resource if the real directory is already there in the project structure. You can try something like this:
On disk, rename/move the directory in question
Refresh the project, the directory is gone
Create a linked resource ( New -> File/Folder >> Advanced -> Link to file in the file system ). Name it the same as the original directory.
On disk, restore the original name of the directory
Refresh project.
Try right-clicking "Properties" and unchecking all permissions.