This is the simplest way to install the Ceyon IDE Eclipse plugin.
-
Follow the instructions found there :
-
Restart Eclipse.
-
Go to
Help > Welcome to Ceylon
to get started.
If you want to have an up-to-date version of the Ceylon IDE based on the lastest code of all Ceylon projects, this is the prefered method.
- First make sure that your Eclipse can be run by simply typing the
eclipse
command (either by adding theeclipse
command full path to the PATH environment variable, or by creating a symbolic link to theeclipse
executable file in a directory already visible in the PATH).
1b. Make sure that your ant (latest version) and maven (Version in Range from 3.0.5 to 3.2.1) can also be run on the command line.
-
Make sure that your JAVA_HOME is set to the right JDK 7 installation
-
Make sure that the following GitHub repositories have all been cloned locally into the same parent directory :
- ceylon-dist
- ceylon-sdk
- ceylon.formatter
- ceylon-ide-eclipse
-
Build a full Ceylon distribution locally (see here for more details) :
- In the
ceylon-dist
directory run :ant clean publish-all ide-quick
- This should have produced an eclipse update site available at the following path :
.../ceylon-dist/osgi/build/dist
- In the
-
Build the Ceylon SDK locally :
- In the
ceylon-sdk
directory run :ant clean publish ide-quick
- This should have produced an eclipse update site available at the following path :
.../ceylon-sdk/osgi/dist
- In the
-
Build the Ceylon Formatter locally (see here for more details) :
- In the
ceylon.formatter
directory run :ant clean publish ide-quick
- This should have produced an eclipse update site available at the following path :
.../ceylon.formatter/osgi/dist
- In the
-
From this directory (
ceylon-ide-eclipse
), type :`mvn clean install -fae`
To skip tests completely you can do:
`mvn clean install -DskipTests`
-
The directory
site/target/repository
now contains an update site you can install from.
This method implies some additional complexity, and is only useful if you want to debug the Ceylon IDE plugin.
Prelimiary remark : Now, parts of the Ceylon IDE project itself are written in Ceylon. Thus, in order to develop the Ceylon IDE plugin, you must have a previous version of the plugin installed in your main Eclipse (either downloaded from the update site, or built with Maven).
Then :
-
Start with a clean install of Eclipse Kepler or Luna.
-
Install the following feature : Graphical Editing Framework Zest Visualization Toolkit SDK available at the main Eclipse release update site (http://download.eclipse.org/releases/kepler for the Kepler version)
-
Install a previous version of the Ceylon IDE (either downloaded from the update site, or built with Maven)
-
Make sure you have the following feature : Eclipse Plug-in Development Environment. This is normally included inside the Eclipse Standard Package.
-
Use
File > Import... > Existing Projects into Workspace
to import the Java projects that are in these directories :ceylon-ide-eclipse/plugins/com.redhat.ceylon.eclipse.ui ceylon-ide-eclipse/plugins/com.redhat.ceylon.test.eclipse.plugin ceylon-ide-eclipse/plugins/com.redhat.ceylon.eclipse.android.plugin ceylon-ide-eclipse/plugins/com.redhat.ceylon.eclipse.ui.jdt.debug.fragment
And also the Ceylon project that is the following directory :
ceylon-ide-eclipse/plugins/com.redhat.ceylon.eclipse.ui/ceylon
-
The
com.redhat.ceylon.eclipse.ui
plugin depends on several OSGI bundles, which must be available inside Eclipse to be able to build it. Quite recent versions of these dependencies should be available on the IDE development update site in the Ceylon IDE Runtime Bundles category. Though installing all the bundles of this category will provide the dependencies required to build and run the Ceylon IDE, this is not recommended. Indeed this method is only useful if you don't have the Ceylon distribution projects installed locally, or if you don't want to take in account changes made locally to the required bundles.So, if you need to build the IDE with the very last versions of the dependencies (ceylon compiler, typechecker, etc), you will need to :
-
build a full Ceylon distribution locally first (see here for more details) :
- First make sure that your Eclipse can be run by simply typing the
eclipse
command (either by adding theeclipse
command full path to the PATH environment variable, or by creating a symbolic link to theeclipse
executable file in a directory already visible in the PATH). - In the
ceylon-dist
directory run :ant clean publish-all ide-quick
- This should have produced an eclipse update site available at the following path :
.../ceylon-dist/osgi/build/dist
- Add this folder as a local update site in your Eclipse Available Software Sites list.
- From this new update site, install only the
Ceylon Distribution Binary Dependencies Feature
available under theCeylon Distribution - Only Binary Dependencies
category. This provides (as OSGI bundles) only the external archives required by the various siblings projects of the local ceylon dist (jboss modules, etc ...).
- First make sure that your Eclipse can be run by simply typing the
-
build the Ceylon SDK :
- In the
ceylon-sdk
directory run :ant clean publish ide-quick
- In the
-
build the ceylon.formatter module that is also required now (see here for more details):
- In the
ceylon.formatter
directory run :ant clean publish ide-quick
- In the
-
make sure that the following GitHub repositories have all been cloned locally into the same parent directory :
ceylon-dist ceylon-sdk ceylon.formatter ceylon-ide-eclipse
-
Import inside your Eclipse workspace the
ceylon-dist-osgi
project found at the following location :.../ceyon-dist/osgi
-
Import inside your Eclipse workspace the
ceylon-dist-osgi-embedded-repository
project found at the following location :.../ceyon-dist/osgi/embeddedRepository
-
Import inside your Eclipse workspace all the required bundle-proxys projects found under the following location :
.../ceyon-ide-eclipse/required-bundle-proxies
Since the Ceylon Distribution modules have circular dependencies on each others, it happens that those circular dependencies are reproduced by the ceylon-dist-osgi and bundle-proxys projects. In order to be able to build you projects, you will have to allow cycles in the Java build paths by setting the following Eclipse preference
Java -> Compiler -> Build -> Circular Dependencies
towarning
Each time you will rebuild one of the projects required by the Ceylon IDE plugin (distribution, SDK, formatter, ...), you only need to Refresh the
ceylon-dist-osgi
project, as well as the bundle proxy projects related to the rebuilt required projects, in order to be able to see the changes in the Ceylon IDE projects. However :- If you update the dependencies of libs in the Ceylon distrib repo, you must update your
Ceylon Distribution Binary Dependencies Feature
plugin from the.../ceylon-dist/osgi/build/dist
update site. - If you update the sdk, ceylon.formatter or Ceylon distrib, you need to redo the
ant clean publish ide
in each project and refresh them in Eclipse and possible clean their proxy bundle projects and theceylon-dist-osgi
project.
-
-
If you want to modify / add IDE tests, you should also add the test plugin. For this purpose
-
Add the SWTBot Eclipse features, which are required to compile and run the Ceylon IDE interactive tests. Install all the features available at the following update site :
http://download.eclipse.org/technology/swtbot/releases/latest/
-
Use
File > Import... > Existing Projects into Workspace
to import the project from this root directory:ceylon-ide-eclipse/tests/com.redhat.ceylon.eclipse.ui.test
-
-
Select the
com.redhat.ceylon.eclipse.ui
project and run it usingRun > Run As > Eclipse Application
. Now go to the new instance of Eclipse. -
Go to
Help > Welcome to Ceylon
to get started.
-
Total panic
-
It's a nightmare
-
For proxy bundles, I used:
for f in *-1.1.0.?ar; do newf=${f/1.1.0/1.1.1}; if test ! -d $newf; then mkdir $newf; fi; cp $f/{.classpath,.project,.gitignore} $newf/; perl -pi -e 's/1.1.0/1.1.1/g' $newf/{.classpath,.project,.gitignore}; done
-
Build with Tycho/Maven 3 (see previous section)
-
Copy (through sftp) the content of the directory
site/target/repository
onto the server :www.ceylon-lang.org
to the following directory :
/var/www/downloads.ceylonlang/ide/dev
The content of this repository is released under the EPL v1.0 as provided in the LICENSE file that accompanied this code.
By submitting a "pull request" or otherwise contributing to this repository, you agree to license your contribution under the license mentioned above.