pom.xml revision 409070ff
1<?xml version="1.0" encoding="UTF-8"?>
2<!-- vi: set et smarttab sw=4 tabstop=4: -->
3<!--
4 Copyright (c) 2015 Cisco and/or its affiliates.
5 Licensed under the Apache License, Version 2.0 (the "License");
6 you may not use this file except in compliance with the License.
7 You may obtain a copy of the License at:
8
9     http://www.apache.org/licenses/LICENSE-2.0
10
11 Unless required by applicable law or agreed to in writing, software
12 distributed under the License is distributed on an "AS IS" BASIS,
13 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 See the License for the specific language governing permissions and
15 limitations under the License.
16-->
17<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
18
19  <parent>
20    <groupId>io.fd.honeycomb.common</groupId>
21    <artifactId>honeycomb-parent</artifactId>
22    <version>1.18.04-SNAPSHOT</version>
23    <relativePath>../honeycomb-parent</relativePath>
24  </parent>
25
26  <modelVersion>4.0.0</modelVersion>
27  <artifactId>impl-parent</artifactId>
28  <name>${project.artifactId}</name>
29  <version>1.18.04-SNAPSHOT</version>
30  <packaging>pom</packaging>
31
32  <properties>
33    <guice.version>4.1.0</guice.version>
34    <guice.config.version>1.2.0</guice.config.version>
35    <skinny.logback.version>1.0.8</skinny.logback.version>
36    <maven-resources-plugin.version>3.0.2</maven-resources-plugin.version>
37  </properties>
38
39  <dependencyManagement>
40    <dependencies>
41      <!-- DI -->
42      <dependency>
43        <groupId>com.google.inject</groupId>
44        <artifactId>guice</artifactId>
45        <version>${guice.version}</version>
46      </dependency>
47      <dependency>
48        <groupId>net.jmob</groupId>
49        <artifactId>guice.conf</artifactId>
50        <version>${guice.config.version}</version>
51      </dependency>
52      <dependency>
53        <groupId>com.google.inject.extensions</groupId>
54        <artifactId>guice-multibindings</artifactId>
55        <version>${guice.version}</version>
56      </dependency>
57      <!-- tests -->
58      <dependency>
59        <groupId>org.skinny-framework</groupId>
60        <artifactId>skinny-logback</artifactId>
61        <version>${skinny.logback.version}</version>
62        <scope>test</scope>
63      </dependency>
64      <dependency>
65        <groupId>com.google.inject.extensions</groupId>
66        <artifactId>guice-testlib</artifactId>
67        <version>${guice.version}</version>
68        <scope>test</scope>
69      </dependency>
70    </dependencies>
71  </dependencyManagement>
72
73  <build>
74    <pluginManagement>
75      <!-- Must be done in parent, to unpack jars for all projects that we generate yang module index for -->
76      <plugins> <!-- Copy all dependencies -->
77        <plugin>
78          <groupId>org.apache.maven.plugins</groupId>
79          <artifactId>maven-dependency-plugin</artifactId>
80          <version>2.10</version>
81          <executions>
82            <execution>
83              <id>copy-dependencies</id>
84              <!-- Must be done before generating yang to module index -->
85              <phase>process-sources</phase>
86              <goals>
87                <goal>copy-dependencies</goal>
88              </goals>
89              <configuration>
90                <outputDirectory>${project.build.directory}/lib</outputDirectory>
91                <useBaseVersion>true</useBaseVersion>
92                <useRepositoryLayout>true</useRepositoryLayout>
93                <excludeArtifactIds>yang-jmx-generator,test-api</excludeArtifactIds>
94              </configuration>
95            </execution>
96          </executions>
97        </plugin>
98        <!-- Generate module to yang provider index -->
99        <plugin>
100          <groupId>org.codehaus.gmaven</groupId>
101          <artifactId>groovy-maven-plugin</artifactId>
102          <executions>
103            <execution>
104              <id>generate-yang-index</id>
105              <phase>generate-resources</phase>
106              <goals>
107                <goal>execute</goal>
108              </goals>
109              <configuration>
110                <source>
111                  io.fd.honeycomb.common.scripts.ModuleYangIndexGenerator.generateIndexForPresentModules(project, log)
112                </source>
113              </configuration>
114            </execution>
115          </executions>
116          <dependencies>
117            <dependency>
118              <groupId>io.fd.honeycomb.common</groupId>
119              <artifactId>common-scripts</artifactId>
120              <version>1.18.04-SNAPSHOT</version>
121            </dependency>
122          </dependencies>
123        </plugin>
124      </plugins>
125    </pluginManagement>
126
127    <plugins>
128      <plugin>
129        <groupId>org.codehaus.gmaven</groupId>
130        <artifactId>groovy-maven-plugin</artifactId>
131      </plugin>
132    </plugins>
133
134    <resources>
135      <resource>
136        <directory>src/main/resources</directory>
137        <includes>
138          <include>**/*</include>
139        </includes>
140      </resource>
141      <resource>
142        <directory>${project.build.outputDirectory}</directory>
143        <includes>
144          <include>**/yang-modules-binding/yang-modules</include>
145        </includes>
146      </resource>
147    </resources>
148  </build>
149</project>
150