Project

General

Profile

1
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
2
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
3
	<modelVersion>4.0.0</modelVersion>
4
	<groupId>edu.ucsb.nceas.metacat.common</groupId>
5
	<artifactId>metacat-common</artifactId>
6
	<packaging>jar</packaging>
7
	<version>2.2.0-SNAPSHOT</version>
8
	<name>metacat-common</name>
9
	<url>http://maven.apache.org</url>
10
	<properties>
11
        <d1_solr_index_schema_name>index-solr-schema-v1_1.xml</d1_solr_index_schema_name>
12
        <d1_solr_index_schema_url>scm:svn:https://repository.dataone.org/software/cicore/tags/DATAONE-CN-INDEX_v1.2.0/usr/share/dataone-cn-index</d1_solr_index_schema_url>         
13
    </properties>
14
	<repositories>
15
        <repository>
16
            <id>dataone.org</id>
17
            <url>http://dev-testing.dataone.org/maven</url>
18
            <releases>
19
                <enabled>true</enabled>
20
            </releases>
21
            <snapshots>
22
                <enabled>true</enabled>
23
            </snapshots>
24
        </repository>
25
    </repositories>
26
	<dependencies>
27
		<dependency>
28
			<groupId>junit</groupId>
29
			<artifactId>junit</artifactId>
30
			<version>4.8.2</version>
31
			<scope>test</scope>
32
		</dependency>
33
		<dependency>
34
            <groupId>javax.servlet</groupId>
35
            <artifactId>servlet-api</artifactId>
36
            <version>2.5</version>
37
            <type>jar</type>
38
            <scope>test</scope>
39
        </dependency>
40
		<dependency>
41
			<groupId>org.apache.solr</groupId>
42
			<artifactId>solr-core</artifactId>
43
			<version>3.4.0</version>
44
		</dependency>
45
		<dependency>
46
			<groupId>org.apache.solr</groupId>
47
			<artifactId>solr-test-framework</artifactId>
48
			<version>3.4.0</version>
49
		</dependency>
50
		<dependency>
51
			<groupId>org.dataone</groupId>
52
			<artifactId>d1_common_java</artifactId>
53
			<version>1.1.3</version>
54
			<type>jar</type>
55
			<!-- exclude extraneous artifacts (jars) -->
56
			<exclusions>
57
		        <exclusion>
58
		          <groupId>org.jibx</groupId>
59
		          <artifactId>jibx-tools</artifactId>
60
		        </exclusion>
61
		        <exclusion>
62
		          <groupId>org.jibx</groupId>
63
		          <artifactId>jibx-schema</artifactId>
64
		        </exclusion>
65
		        <exclusion>
66
		          <groupId>org.jibx</groupId>
67
		          <artifactId>jibx-extras</artifactId>
68
		        </exclusion>
69
		        <exclusion>
70
		          <groupId>org.jibx</groupId>
71
		          <artifactId>jibx-bind</artifactId>
72
		        </exclusion>
73
		        <exclusion>
74
		        	<groupId>org.apache.maven.plugins</groupId>
75
					<artifactId>maven-compiler-plugin</artifactId>
76
		        </exclusion>
77
		        <exclusion>
78
		        	<groupId>org.apache.maven.plugins</groupId>
79
					<artifactId>maven-jar-plugin</artifactId>
80
		        </exclusion>
81
		        <exclusion>
82
		        	<groupId>org.apache.maven.plugins</groupId>
83
					<artifactId>maven-clean-plugin</artifactId>
84
		        </exclusion>
85
		        <exclusion>
86
		        	<groupId>org.jibx</groupId>
87
					<artifactId>maven-jibx-plugin</artifactId>
88
		        </exclusion>
89
			</exclusions>
90
		</dependency>
91
	</dependencies>
92
	<build>
93
	   <resources>
94
            <resource>
95
                <directory>src/main/resources</directory>
96
                <excludes>
97
                    <exclude>solr-home/**</exclude>
98
                </excludes>
99
                <filtering>false</filtering>
100
            </resource>
101
        </resources>
102
	   <plugins> 
103
	       <plugin>
104
            <groupId>org.apache.maven.plugins</groupId> 
105
            <artifactId>maven-scm-plugin</artifactId> 
106
            <version>1.8.1</version> 
107
            <executions>
108
                <execution>
109
                    <phase>validate</phase>
110
                    <goals>
111
                        <goal>export</goal>
112
                    </goals>
113
                    <configuration> 
114
                        <connectionType>connection</connectionType> 
115
                        <connectionUrl>${d1_solr_index_schema_url}</connectionUrl > 
116
                    </configuration> 
117
                </execution>
118
            </executions>
119
          </plugin> 
120
          <plugin>
121
                <groupId>org.apache.maven.plugins</groupId>
122
                <artifactId>maven-antrun-plugin</artifactId>
123
                <version>1.7</version>
124
                <executions>
125
                    <execution>
126
                        <id>copy</id>
127
                        <phase>validate</phase>
128
                         <goals>
129
                            <goal>run</goal>
130
                        </goals>
131
                        <configuration>
132
                            <target name="copy and rename file">
133
                                <copy file="target/export/${d1_solr_index_schema_name}" tofile="src/main/resources/solr-home/conf/schema.xml" overwrite="true" />
134
                            </target>
135
                        </configuration>
136
                    </execution>
137
                </executions>
138
        </plugin>
139
        <plugin>
140
            <artifactId>maven-resources-plugin</artifactId>
141
            <version>2.6</version>
142
            <executions>
143
                <execution>
144
                    <id>copy-resources</id>
145
                    <!-- here the phase you need -->
146
                    <phase>validate</phase>
147
                    <goals>
148
                        <goal>copy-resources</goal>
149
                    </goals>
150
                    <configuration>
151
                        <outputDirectory>target/solr-home</outputDirectory>
152
                        <resources>          
153
                            <resource>
154
                                <directory>src/main/resources/solr-home</directory>
155
                                <filtering>false</filtering>
156
                            </resource>
157
                        </resources>
158
                        <overwrite>true</overwrite>              
159
                    </configuration>            
160
                 </execution>
161
                </executions>
162
        </plugin>
163
		<plugin>
164
				<groupId>org.apache.maven.plugins</groupId>
165
				<artifactId>maven-compiler-plugin</artifactId>
166
				<version>2.3</version>
167
				<configuration>
168
					<source>1.6</source>
169
					<target>1.6</target>
170
				</configuration>
171
			</plugin>
172
		</plugins>
173
	</build>
174
</project>
    (1-1/1)