pom.xml 5.7 KB
Newer Older
M
Mathieu Bastian 已提交
1 2
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3 4
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>
5 6
    
    <!-- Parent POM -->
7 8 9
    <parent>
        <groupId>org.gephi</groupId>
        <artifactId>gephi-parent</artifactId>
M
Mathieu Bastian 已提交
10
        <version>0.8.2-SNAPSHOT</version>
11 12
        <relativePath>../..</relativePath>
    </parent>
M
Mathieu Bastian 已提交
13

14 15 16
    <artifactId>gephi-branding</artifactId>
    <packaging>nbm</packaging>
    <name>gephi-branding</name>
M
Mathieu Bastian 已提交
17

18
    <!-- Dependency on the localization ZIP on the 3rd party repository -->
19 20 21 22 23
    <dependencies>
        <dependency>
            <groupId>org.netbeans</groupId>
            <artifactId>platform-localization</artifactId>
            <type>zip</type>
24
            <version>${gephi.platform.localization.version}</version>
25 26
        </dependency>
    </dependencies>
27 28 29 30 31
    
    <properties>  
        <gephi.branding.update.center.official.url>${gephi.update.center.testing.url}</gephi.branding.update.center.official.url>
        <gephi.branding.update.center.thirdparty.url>${gephi.update.center.thirdparty.url}</gephi.branding.update.center.thirdparty.url>
    </properties>
M
Mathieu Bastian 已提交
32

33 34
    <build>
        <plugins>
35 36
            
            <!-- Add localization as NBM resource -->
M
Mathieu Bastian 已提交
37 38 39
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>nbm-maven-plugin</artifactId>
40 41 42 43 44 45 46 47
                <configuration>
                    <nbmResources> 
                        <nbmResource>
                            <directory>${project.build.directory}/localization</directory>
                            <targetPath>.</targetPath>
                        </nbmResource>
                    </nbmResources>
                </configuration>
M
Mathieu Bastian 已提交
48
            </plugin>
49
            
50
            <!-- Copy and filtering tasks -->
51 52 53
            <plugin> 
                <artifactId>maven-resources-plugin</artifactId> 
                <executions> 
54
                    <!-- Copy and replace %{gephi.app.version} variable in two Bundle.properties file that contains the application title -->
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
                    <execution> 
                        <id>generate-bundles</id> 
                        <phase>generate-resources</phase> 
                        <goals> 
                            <goal>copy-resources</goal> 
                        </goals> 
                        <configuration> 
                            <outputDirectory>src/main/nbm-branding</outputDirectory> 
                            <resources> 
                                <resource> 
                                    <directory>src/main/resources</directory> 
                                    <includes> 
                                        <include>core/core.jar/org/netbeans/core/startup/Bundle.properties</include>
                                        <include>modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/view/ui/Bundle.properties</include>
                                    </includes> 
                                    <filtering>true</filtering> 
                                </resource> 
                            </resources> 
                        </configuration> 
                    </execution> 
75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94
                    
                    <execution> 
                        <id>generate-autoudate-urls</id> 
                        <phase>generate-resources</phase> 
                        <goals> 
                            <goal>copy-resources</goal> 
                        </goals> 
                        <configuration>
                            <outputDirectory>${basedir}/target/classes</outputDirectory> 
                            <resources> 
                                <resource> 
                                    <directory>src/main/resources</directory> 
                                    <includes> 
                                        <include>org/gephi/branding/Bundle.properties</include>
                                    </includes> 
                                    <filtering>true</filtering> 
                                </resource> 
                            </resources> 
                        </configuration> 
                    </execution> 
95 96 97
                </executions> 
            </plugin>
            
98
            <!-- Unpack the localization dependency -->
99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <executions>
                    <execution>
                        <id>unpack</id>
                        <phase>package</phase>
                        <goals>
                            <goal>unpack-dependencies</goal>
                        </goals>
                        <configuration>
                            <includeGroupIds>org.netbeans</includeGroupIds>
                            <includeArtifactIds>platform-localization</includeArtifactIds>
                            <outputDirectory>
                                ${project.build.directory}/localization
                            </outputDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
121 122 123 124 125 126 127 128 129 130
    
    <profiles>
        <!-- The deployment profile is built for daily releases. It builts everything except the installers -->
        <profile>
            <id>release</id>
            <properties>
                <gephi.branding.update.center.official.url>${gephi.update.center.official.url}</gephi.branding.update.center.official.url>
            </properties>
        </profile>
    </profiles>
M
Mathieu Bastian 已提交
131
</project>