I wrote a simple Hello World program with the Ceylon Eclipse plugin:
Here is the source code, in case anybody wants to reproduce the issue quickly:
shared void main() {
String omg = (process.arguments.first else "nothing");
print("You wrote ``omg``, you silly programmer!");
}
Now, I can run this program just fine from within Eclipse. But how do I run it from the terminal?
I don't have the Ceylon command line tools installed, and I would prefer it to stay that way. When I give my program to other people, I don't want them having to install Ceylon either.
There seems to be only one class file:
~/workspace/saloon $ find . -type f -name "*.class"
./.exploded/main_.class
If I try to run that, I get:
~/workspace/saloon/.exploded $ java main_
Exception in thread "main" java.lang.NoClassDefFoundError: ceylon/language/process_
at main_.main(main.ceylon)
Caused by: java.lang.ClassNotFoundException: ceylon.language.process_
at java.net.URLClassLoader$1.run(URLClassLoader.java:372)
at java.net.URLClassLoader$1.run(URLClassLoader.java:361)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:360)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 1 more
The Eclipse project does not seem to depend on any .jar
files, only one .car
file, but java
does not work with .car
files. Running Scala Eclipse projects from the terminal is easy peasy by providing the appropriate .jar
files.
So how do I run Ceylon Eclipse projects from the terminal via java
? Or is this impossible?