<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>hu.blackbelt.judo.meta</groupId>
    <artifactId>hu.blackbelt.judo.meta.jsl</artifactId>
    <version>1.0.0</version>
  </parent>
  <groupId>hu.blackbelt.judo.meta</groupId>
  <artifactId>hu.blackbelt.judo.meta.jsl.model</artifactId>
  <version>1.0.0</version>
  <packaging>eclipse-plugin</packaging>
  <name>Judo :: Jsl :: Model :: Eclipse plugin</name>
  <description>Judo Jsl model eclipse plugin</description>
  <licenses>
    <license>
      <name>Eclipse Public License 2.0</name>
      <url>https://www.eclipse.org/org/documents/epl-2.0/EPL-2.0.txt</url>
    </license>
  </licenses>
  <properties>
    <src.dir>src/main/java</src.dir>
  </properties>
  <dependencies>
    <dependency>
      <groupId>org.eclipse.platform</groupId>
      <artifactId>org.eclipse.ui.workbench</artifactId>
      <version>3.126.0</version>
      <exclusions>
        <exclusion>
          <groupId>com.sun.jna</groupId>
          <artifactId>com.sun.jna</artifactId>
        </exclusion>
        <exclusion>
          <groupId>com.sun.jna</groupId>
          <artifactId>com.sun.jna.platform</artifactId>
        </exclusion>
        <exclusion>
          <groupId>javax.annotation</groupId>
          <artifactId>javax.annotation-api</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.eclipse.platform</groupId>
          <artifactId>org.eclipse.swt</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.eclipse.birt.runtime</groupId>
          <artifactId>org.w3c.css.sac</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.xmlgraphics</groupId>
          <artifactId>batik-css</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.felix</groupId>
          <artifactId>org.apache.felix.scr</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.eclipse.emf</groupId>
          <artifactId>org.eclipse.emf.ecore.xmi</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.eclipse.emf</groupId>
          <artifactId>org.eclipse.emf.ecore</artifactId>
        </exclusion>
        <exclusion>
          <groupId>commons-jxpath</groupId>
          <artifactId>commons-jxpath</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>
    <dependency>
      <groupId>hu.blackbelt.epsilon</groupId>
      <artifactId>epsilon-runtime-execution</artifactId>
    </dependency>
    <dependency>
      <groupId>org.eclipse.xtext</groupId>
      <artifactId>org.eclipse.xtext</artifactId>
      <version>${xtext-version}</version>
      <exclusions>
        <exclusion>
          <groupId>com.google.inject</groupId>
          <artifactId>guice</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.eclipse.xtext</groupId>
      <artifactId>org.eclipse.xtext.xtext.generator</artifactId>
      <version>${xtext-version}</version>
    </dependency>
    <dependency>
      <groupId>com.google.inject</groupId>
      <artifactId>guice</artifactId>
      <version>4.2.3</version>
    </dependency>
    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-text</artifactId>
      <version>1.9</version>
    </dependency>
  </dependencies>
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-clean-plugin</artifactId>
        <configuration>
          <filesets combine.children="append">
            <fileset>
              <directory>${basedir}/src/main/xtext-gen/</directory>
              <includes>
                <include>**/*</include>
              </includes>
            </fileset>
            <fileset>
              <directory>${basedir}/src/main/xtend-gen/</directory>
              <includes>
                <include>**/*</include>
              </includes>
            </fileset>
            <fileset>
              <directory>${basedir}/model/generated/</directory>
            </fileset>
            <fileset>
              <directory>${basedir}/../ide/ui/src/main/xtext-gen/</directory>
              <includes>
                <include>**/*</include>
              </includes>
            </fileset>
            <fileset>
              <directory>${basedir}../ide/ui/src/main/xtend-gen/</directory>
              <includes>
                <include>**/*</include>
              </includes>
            </fileset>
          </filesets>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <executions>
          <execution>
            <id>Generate MWE2 class dependencies</id>
            <phase>generate-sources</phase>
            <goals>
              <goal>compile</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <includes>hu/blackbelt/judo/meta/jsl/JslXtextProjectConfig.java</includes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>exec-maven-plugin</artifactId>
        <version>3.1.0</version>
        <executions>
          <execution>
            <id>mwe2Launcher-builder</id>
            <phase>generate-sources</phase>
            <goals>
              <goal>java</goal>
            </goals>
            <configuration>
              <mainClass>org.eclipse.emf.mwe2.launch.runtime.Mwe2Launcher</mainClass>
              <arguments>
                <argument>/${project.basedir}/src/main/java/hu/blackbelt/judo/meta/jsl/GenerateJslDsl.mwe2</argument>
                <argument>-p</argument>
                <argument>rootPath=/${project.basedir}/..</argument>
              </arguments>
              <classpathScope>compile</classpathScope>
              <includePluginDependencies>true</includePluginDependencies>
              <cleanupDaemonThreads>false</cleanupDaemonThreads>
            </configuration>
          </execution>
        </executions>
        <dependencies>
          <dependency>
            <groupId>org.eclipse.emf</groupId>
            <artifactId>org.eclipse.emf.mwe2.launch</artifactId>
            <version>${emf-mwe2-launch-version}</version>
          </dependency>
        </dependencies>
      </plugin>
      <plugin>
        <groupId>org.eclipse.xtend</groupId>
        <artifactId>xtend-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
        <version>3.3.0</version>
        <executions>
          <execution>
            <id>add-genmodel-source</id>
            <phase>generate-sources</phase>
            <goals>
              <goal>add-source</goal>
            </goals>
            <configuration>
              <sources>
                <source>${project.basedir}/src/main/xtext-gen</source>
                <source>${project.basedir}/src/main/xtend-gen</source>
              </sources>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
</project>
