Generate code from flatbuffers by default
- Id
- 3a0d1d3a4adf47b19f9a885c2eb51c130fd9cfd5
- Author
- Caio
- Commit time
- 2019-01-21T09:38:55+01:00
Modified pom.xml
<verbose>false</verbose>
</configuration>
</plugin>
+ <!-- flatbuffers start -->
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <version>3.1.1</version>
+ <executions>
+ <execution>
+ <id>unpack</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>unpack</goal>
+ </goals>
+ <configuration>
+ <artifactItems>
+ <artifactItem>
+ <groupId>com.github.davidmoten</groupId>
+ <artifactId>flatbuffers-compiler</artifactId>
+ <version>${flatbuffers.version}</version>
+ <type>tar.gz</type>
+ <classifier>distribution-linux</classifier>
+ <overWrite>true</overWrite>
+ <outputDirectory>${project.build.directory}</outputDirectory>
+ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>exec-maven-plugin</artifactId>
+ <version>1.6.0</version>
+ <executions>
+ <execution>
+ <goals>
+ <goal>exec</goal>
+ </goals>
+ <phase>generate-sources</phase>
+ </execution>
+ </executions>
+ <configuration>
+ <executable>${project.build.directory}/bin/flatc</executable>
+ <workingDirectory>${flatbuffers.sources}</workingDirectory>
+ <arguments>
+ <argument>--java</argument>
+ <argument>-o</argument>
+ <argument>${flatbuffers.generated.sources}</argument>
+ <argument>recipe.fbs</argument>
+ </arguments>
+ </configuration>
+ </plugin>
+ <plugin>
+ <groupId>org.codehaus.mojo</groupId>
+ <artifactId>build-helper-maven-plugin</artifactId>
+ <version>3.0.0</version>
+ <executions>
+ <execution>
+ <id>add-source</id>
+ <phase>generate-sources</phase>
+ <goals>
+ <goal>add-source</goal>
+ </goals>
+ <configuration>
+ <sources>
+ <source>${flatbuffers.generated.sources}</source>
+ </sources>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <!-- flatbuffers end -->
</plugins>
</build>
<profiles>
- <profile>
- <id>flatbuffers</id>
- <build>
- <plugins>
- <!-- flatbuffers start -->
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-dependency-plugin</artifactId>
- <version>3.1.1</version>
- <executions>
- <execution>
- <id>unpack</id>
- <phase>generate-sources</phase>
- <goals>
- <goal>unpack</goal>
- </goals>
- <configuration>
- <artifactItems>
- <artifactItem>
- <groupId>com.github.davidmoten</groupId>
- <artifactId>flatbuffers-compiler</artifactId>
- <version>${flatbuffers.version}</version>
- <type>tar.gz</type>
- <classifier>distribution-linux</classifier>
- <overWrite>true</overWrite>
- <outputDirectory>${project.build.directory}</outputDirectory>
- </artifactItem>
- </artifactItems>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>exec-maven-plugin</artifactId>
- <version>1.6.0</version>
- <executions>
- <execution>
- <goals>
- <goal>exec</goal>
- </goals>
- <phase>generate-sources</phase>
- </execution>
- </executions>
- <configuration>
- <executable>${project.build.directory}/bin/flatc</executable>
- <workingDirectory>${flatbuffers.sources}</workingDirectory>
- <arguments>
- <argument>--java</argument>
- <argument>-o</argument>
- <argument>${flatbuffers.generated.sources}</argument>
- <argument>recipe.fbs</argument>
- </arguments>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>build-helper-maven-plugin</artifactId>
- <version>3.0.0</version>
- <executions>
- <execution>
- <id>add-source</id>
- <phase>generate-sources</phase>
- <goals>
- <goal>add-source</goal>
- </goals>
- <configuration>
- <sources>
- <source>${flatbuffers.generated.sources}</source>
- </sources>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <!-- flatbuffers end -->
- </plugins>
- </build>
- </profile>
<profile>
<id>index</id>
<build>