Skip to content
An Xtext language and example usage of it built with Maven
Branch: master
Clone or download
kthoms Merge pull request #60 from xtext/fixes
Fixed problems with Java 11 and Tycho + Xtext 2.17
Latest commit dbca615 Apr 5, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
example-project-gradle Fixed problems with Java 11 and Tycho Apr 5, 2019
example-project Fixed problems with Java 11 and Tycho Apr 5, 2019
my.mavenized.herolanguage.ide update to Xtext 2.16 Dec 17, 2018
my.mavenized.herolanguage.sdk fixed updatesite #57 Jan 24, 2019
my.mavenized.herolanguage.tests Fixed problems with Java 11 and Tycho Apr 5, 2019
my.mavenized.herolanguage.ui
my.mavenized.herolanguage.updatesite Fixed README incl adding hint to Maven Archetype Jul 22, 2017
my.mavenized.herolanguage Fixed problems with Java 11 and Tycho Apr 5, 2019
.gitignore Fixed README incl adding hint to Maven Archetype Jul 22, 2017
.project [eclipse/xtext#1183] Rename project from "root" to "parent". May 15, 2018
.travis.yml Fixed builds with Java 11 as Host JDK Jan 9, 2019
README.md Update README.md Jan 10, 2019
pom.xml

README.md

Build Status

An Xtext Language Built with Maven

A small example to show how to configure a Maven build for an Xtext language and how to use it from Maven and Gradle.

Language Build

If you use Xtext 2.9 or higher, the Maven build for your language is auto-generated. Just skip ahead to the usage section.

  • see my.mavenized.herolanguage.* projects
  • Language plug-ins, updatesite and Eclipse feature built via Maven/Tycho
  • Xtext Code Generation (Language infrastructure generated from grammar)
  • Xtend Code Generation

Language Usage

  • example-project
  • example-project-gradle
  • Example Language (herolanguage) Code Generation
  • Xtend Code Generation

Try it out!

Steps

1. Increase memory

   export MAVEN_OPTS="-Xmx512m -XX:MaxPermSize=256m"

2. Build the language

 mvn clean install

3. Build the example projects

 cd ../example-project/
 mvn clean install
 cd ../example-project-gradle/
 ./gradlew build

Builds

We now have automatic builds:

https://travis-ci.org/xtext/maven-xtext-example

Maven Archetype

There is also a Maven Archetype available that automatically creates your new project based on this example: https://github.com/fuinorg/emt-xtext-archetype

Known Issues

1. Build fails due to version conflicts

The build will fail immediately because of version conflicts. A possible error might look similar to the following:

  • No versions available for org.eclipse.emf:org.eclipse.emf.mwe2.runtime:jar:[2.9.1.201705291010] within specified range

Even if the specified version (see pom) is available on the central maven repository, updating related snapshots will most likely help the problem.

  • mvn clean install -U
You can’t perform that action at this time.