score:329

Accepted answer

if you mean "change workspace" go to file -> switch workspace

score:-1

you can check the option that shows up when you start eclipse. please see the figure below

enter image description here

score:0

if you want to create a new workspace - simply enter a new path in the textfield at the "select workspace" dialog. eclipse will create a new workspace at that location and switch to it.

score:0

on ubuntu i went to

~/.eclipse/org.eclipse.platform_4.3.0_1473617060_linux_gtk_x86_64/configuration/config.ini 

and added this line at the bottom

osgi.instance.area.default=@user.home/workspace

and changed workspace to the dir path from my home to where i put my workspace.

i combined @frank answer with @ronan quillevere's comment

score:0

my kepler eclipse went into not responding at boot (shortly after installing gae support) which i traced to a corrupt workspace. i fixed this by closing kepler, renaming the workspace directory (in use) so kepler starts normally without a workspace, then used file >> switch workspace to generate new workspace. then started populating that with my old projects that i still needed.

score:1

in eclipse, go to file -> switch workspace, choose or create a new workspace.

score:1

this is the only answer you got first when you search for default workspace, but any solution is not solved my problem, so i follow this step for a default workspace:

  1. first copy shortcut icon for your eclipse.
  2. right click and go to properties, add your workspace path with -data attribute,

in target:

d:\eclipse_path\eclipse.exe -clean -data d:\workspace_path\workspace

enter image description here

for using the same shortcuts and preference into this workspace, export general --> preference from your working eclipse, it will generate one .epf file.

so, just import .epf file into your new workspace, and you are done.

enter image description here

score:4

open a command prompt. change to the eclipse home directory and type "eclipse -clean" e.g. c:/eclipse>eclipse -clean

this will ask for the workspace selection. it will also force to set it as the default workspace.

then, go to eclipsehome-->configuration-->settings folder.

open org.eclipse.ui.de.prefs in a notepad.

set this property to true from false.

show_workspace_selection_dialog=true

you will be asked for a workspace selection everytime.

score:4

if you want to change recent workspace manually in a configurationfile org.eclipse.ui.ide.prefs exists in

eclipse > configuration > .settings > org.eclipse.ui.ide.prefs

open this file in an editor find recent_workspaces in line #2 and in this line you can see recent workspaces and can change or even remove them.

score:6

if you mean to change the directory in which the program execution will occur, go to "run configurations" in the run tab.

then select your project and go to the "arguments" tab, you can change the directory there. by default it is the root directory of your project.

score:8

file > switch workspace > add the workspace you like > eclipse will restart using the workspace you wanted.

score:20

whatever frank has suggested to change in config.ini is correct. in case, if that didn't help, you need to remove path from recent workspace as below.

  1. go to eclipse\configuration\org.eclipse.ui.ide.prefs\
  2. open the file "org.eclipse.ui.ide.prefs"
  3. remove the first path in recent_workspaces.

    max_recent_workspaces=5 recent_workspaces=/users/wrokspace1\n/users/wrokspace2\n/users/wrokspace3\n/users/wrokspace4 recent_workspaces_protocol=3
    show_workspace_selection_dialog=false
    eclipse.preferences.version=1

score:28

if you are talking about changing the working directory for a java program that you launch from within eclipse, then there's a space for that in the run configuration. if you go to run menu and select "run configurations..." then select your run configuration, then on the "arguments" tab for a java application there is a place for you to edit the "working directory". this alters the current directory that will be used for launching the java program.

see related question default eclipse working directory if this is what you are meaning.

score:94

  1. go to eclipse\configuration\
  2. open the file "config.ini"
  3. modify the line

    osgi.instance.area.default="f:/workspace/java"
    

    where "f:/workspace/java" should be your default workspace!

score:187

i took this question to mean how can you change the default workspace so that when eclipse boots up the workspace you want is automatically loaded:

  • go under preferences then type "workspace" in the search box provided to filter the list. alternatively you can go to general>startup and shutdown>workspaces.
  • there you can set a flag to make eclipse prompt you to select a workspace at startup by checking the "prompt for workspace at startup" checkbox.
  • you can set the number of previous workspaces to remember also. finally there is a list of recent workspaces. if you just remove all but the one you want eclipse will automatically startup with that workspace.

Related Query

More Query from same tag