XcodeMigration
Introduction
XcodeMigration is a tool written by Pascal Robertto help you migrate multiple WebObjects projects from Xcode to Eclipse/WOLips. If you have complex or many projects to convert, this is the tool to use. The tool is written in Java and is a Eclipse project, so you will need to import the project into Eclipse first (you need a functionnal WOLips installation to be able to import the tool).
How to use it
- If you want to convert your Java classes from MacRoman to UTF-8, make sure your Eclipse workspace is in UTF-8 (the default is MacRoman).
- Make sure that you are in the WOLips perspective
- Download the tool (you don't need to expand the .zip file)
- Import the XcodeMigration tool into Eclipse, by selecting File > Import > Existings projects into workspace. Next. select archive
- Create two templates, one application, the other framework
- should see 3 projects
- open config.xml and change <applicationTemplatePath> and <frameworkTemplatePath>
- for each project that you want to import, you need the a <project> node. <path> is the file system path to the Xcode project, <name> is the project name, minus .xcodeproj
- open the Run dialog
- double-click on Java Application
- click on the arguments tab and enter this value as a program arguments
${project_loc}/config.xml
- click apply and run
- when it's running, you should get a output like this
- to import the converted projects, open File > Import > Existings projects into workspace. Next. select root directory
- your converted projects will appear in the package explorer
- fix all frameworks dependencies and you're done
FAQ
Q. I can't a Could not find working dir for project error when I launch my converted application.
A. Make sure that, in config.xml, <applicationTemplatePath> is set to a WO application instead of a WO framework.
Q. Some of my resources are missing or in the wrong folder.
A. The tool detect files that should be marked as Resources by file extension or name. If a file is not a Java class or one of the file type in the Resources list, the file will be move to the WebServerResources folder instead. You just have to move the files to the Resources folder when needed. If you have file types who should be detected as resources, you can add the needed code in the copyFiles method.
Q. My application is localized and the content in the components are displaying the wrong caracters.
A. If you set the <convertToUTF8> node to true, your Java classes will be converted from MacRoman to UTF-8, but the tool will NOT modify the .woo file so that they use UTF-8. Either you stay in MacRoman and change the value of <convertToUTF8> to false, or you will have to modify your components so that they use UTF-8.