Getting the Eclipse code
- Start with a recent Eclipse build and an empty workspace. We recommend Eclipse SDK 3.5 M4.
- Select File > Import... and select CVS > Projects from CVS, click Next.
- Copy the CVS repository location and paste it into the "Host" field to populate the wizard page: :pserver:email@example.com:/cvsroot/eclipse
- You should see "Host: dev.eclipse.org, Repository path: /cvsroot/eclipse, User: anonymous, Connection type: pserver".
- Click Next and select the second option Use an existing module.
- Drill down as follows: e4 > org.eclipse.e4.server > bundles and select org.eclipse.e4.server.bespin. Click Finish.
Getting the Mozilla code
- Using a web browser, go to http://hg.mozilla.org/labs. The recommended version is 0.3; to get it click on "Bespin" under the "Name" link, scroll to the bottom of the page, and under "Tags", click on the "files" link for version 0.3. On the next page, click on the zip or gz link on the second line. This should download an archive with the Bespin source code version 0.3. (As of this writing, the version at the tip no longer contains the Eclipse project metadata files that 0.3 had, and requires you to add the dojo toolkit.)
- In Eclipse, select File > Import..., pick General > Existing Projects into Workspace, click Next, select the archive file option, click Browse... and select the archive file you just downloaded. Click Open in the file chooser dialog, then check bespin to be imported, and click Finish.
If you have "no project found" message, unzip downloaded file in your eclipse workspace folder. In Eclipse, file -> new -> project -> plug-in project -> copy and paste the name of downloaded folder- click next and click finish
- As a result, you should have a project called bespin in your workspace, containing folders like backend, docs, frontend, etc. and a few files. (Note: If you are adventurous, you could instead install Mercurial and check out the project directly from the Mozilla repository.)
if you have do new -> plug-in project, you must go to Running the server
- Right-click on the bespin project and select PDE Tools > Convert Projects to Plug-in Projects.... Confirm the wizard dialog that opens by clicking Finish. This will generate a plug-in manifest file META-INF/MANIFEST.MF.
Running the server
- Select Run > Run Configurations... and double-click on OSGi Framework to create a new OSGi launch configuration. Click Deselect All and then check:
- Click on Add Required Bundles.
- Optionally, add -Dorg.eclipse.equinox.http.jetty.http.port=8080 as a VM argument on the Arguments tab to change the port on which the server will run.
- Click the Run button.
- Using Firefox 3, open http://localhost or http://localhost:8080 depending on the port your server runs on.
- Click Register and fill in name and password. These are only stored locally.
Running Eclipse-specific Commands
- In Eclipse, Open
dashboard.htmlin a text editor (Ctrl+Shift+R, enter
dashboard.html, click on the triangle next to Open and select Text Editor). The file is located in bepsin/frontend in case you need to navigate to the file and Open With->Text Editor
- Insert the following line after the line that references
- Do the same for
dashboardcommands.jsand add '
newproject' to the list of commands available in the dashboard. The file is located in bespin/frontend/js/commandline.
- Make sure to reload the Bespin page in your web browser, press Ctrl+J to activate the command line, and enter help to see the list of available commands.
You can now create a new project from the dashboard using the newproject command, or check out an existing project available through anonymous CVS using the cvsco command. When in the editor, you can use the problems command to display the list of warnings or errors for the current file.