|
1 | | -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
| 1 | +<project xmlns="http://maven.apache.org/POM/4.0.0" |
| 2 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
2 | 3 | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
3 | 4 | <parent> |
4 | 5 | <artifactId>net.sf.eclipsecs.parent</artifactId> |
|
10 | 11 | <packaging>eclipse-repository</packaging> |
11 | 12 | <name>eclipse-cs Update Site</name> |
12 | 13 |
|
| 14 | + <properties> |
| 15 | + < github-update-repo> [email protected]:Calixte/eclipse-cs-update-site.git</ github-update-repo> |
| 16 | + <github-local-clone>${project.build.directory}/checkout</github-local-clone> |
| 17 | + <releases-directory>${github-local-clone}/releases</releases-directory> |
| 18 | + <current-release-directory>${releases-directory}/${qualifiedVersion}</current-release-directory> |
| 19 | + <site.label>Eclipse Checkstyle Plugin Update Site</site.label> |
| 20 | + </properties> |
| 21 | + |
13 | 22 | <profiles> |
14 | 23 | <profile> |
15 | | - <id>bintray</id> |
| 24 | + <id>release-composite</id> |
16 | 25 | <build> |
17 | 26 | <plugins> |
18 | | - <!-- Enable alternative deployer. --> |
19 | 27 | <plugin> |
20 | | - <groupId>com.carrotgarden.maven</groupId> |
21 | | - <artifactId>bintray-maven-plugin</artifactId> |
| 28 | + <groupId>org.codehaus.mojo</groupId> |
| 29 | + <artifactId>build-helper-maven-plugin</artifactId> |
| 30 | + <executions> |
| 31 | + <execution> |
| 32 | + <id>parse-version</id> |
| 33 | + <goals> |
| 34 | + <goal>parse-version</goal> |
| 35 | + </goals> |
| 36 | + </execution> |
| 37 | + </executions> |
| 38 | + </plugin> |
| 39 | + <plugin> |
| 40 | + <groupId>org.codehaus.mojo</groupId> |
| 41 | + <artifactId>exec-maven-plugin</artifactId> |
22 | 42 | <configuration> |
23 | | - <skip>false</skip> |
24 | | - <subject>eclipse-cs</subject> |
25 | | - <repository>eclipse-cs</repository> |
26 | | - <!-- Put Bintray credentials in settings.xml. --> |
27 | | - <serverId>bintray</serverId> |
| 43 | + <executable>git</executable> |
28 | 44 | </configuration> |
29 | 45 | <executions> |
30 | 46 | <execution> |
31 | | - <id>upload-update-site</id> |
32 | | - <phase>deploy</phase> |
| 47 | + <id>git-clone</id> |
| 48 | + <phase>prepare-package</phase> |
| 49 | + <goals> |
| 50 | + <goal>exec</goal> |
| 51 | + </goals> |
| 52 | + <configuration> |
| 53 | + <arguments> |
| 54 | + <argument>clone</argument> |
| 55 | + <argument>--depth=1</argument> |
| 56 | + <argument>-b</argument> |
| 57 | + <argument>main</argument> |
| 58 | + <argument>${github-update-repo}</argument> |
| 59 | + <argument>${github-local-clone}</argument> |
| 60 | + </arguments> |
| 61 | + </configuration> |
| 62 | + </execution> |
| 63 | + <execution> |
| 64 | + <id>git-add</id> |
| 65 | + <phase>verify</phase> |
| 66 | + <goals> |
| 67 | + <goal>exec</goal> |
| 68 | + </goals> |
| 69 | + <configuration> |
| 70 | + <arguments> |
| 71 | + <argument>-C</argument> |
| 72 | + <argument>${github-local-clone}</argument> |
| 73 | + <argument>add</argument> |
| 74 | + <argument>-A</argument> |
| 75 | + </arguments> |
| 76 | + </configuration> |
| 77 | + </execution> |
| 78 | + <execution> |
| 79 | + <id>git-commit</id> |
| 80 | + <phase>verify</phase> |
33 | 81 | <goals> |
34 | | - <goal>upload</goal> |
| 82 | + <goal>exec</goal> |
35 | 83 | </goals> |
36 | 84 | <configuration> |
37 | | - <bintrayPackage>update-site</bintrayPackage> |
38 | | - <bintrayVersion>${unqualifiedVersion}</bintrayVersion> |
39 | | - <sourceFolder>${project.build.directory}/repository/</sourceFolder> |
40 | | - <targetFolder>${unqualifiedVersion}</targetFolder> |
41 | | - <performCleanup>true</performCleanup> |
42 | | - <cleanupRegex>^\Q${unqualifiedVersion}\E.*$</cleanupRegex> |
| 85 | + <arguments> |
| 86 | + <argument>-C</argument> |
| 87 | + <argument>${github-local-clone}</argument> |
| 88 | + <argument>commit</argument> |
| 89 | + <argument>-m</argument> |
| 90 | + <argument>Release ${qualifiedVersion}</argument> |
| 91 | + </arguments> |
43 | 92 | </configuration> |
44 | 93 | </execution> |
45 | 94 | <execution> |
46 | | - <id>upload-update-site-archive</id> |
| 95 | + <id>git-push</id> |
47 | 96 | <phase>deploy</phase> |
48 | 97 | <goals> |
49 | | - <goal>upload</goal> |
| 98 | + <goal>exec</goal> |
| 99 | + </goals> |
| 100 | + <configuration> |
| 101 | + <arguments> |
| 102 | + <argument>-C</argument> |
| 103 | + <argument>${github-local-clone}</argument> |
| 104 | + <argument>push</argument> |
| 105 | + <argument>origin</argument> |
| 106 | + <argument>main</argument> |
| 107 | + </arguments> |
| 108 | + </configuration> |
| 109 | + </execution> |
| 110 | + </executions> |
| 111 | + </plugin> |
| 112 | + <plugin> |
| 113 | + <artifactId>maven-resources-plugin</artifactId> |
| 114 | + <executions> |
| 115 | + <execution> |
| 116 | + <id>copy-repository</id> |
| 117 | + <phase>package</phase> |
| 118 | + <goals> |
| 119 | + <goal>copy-resources</goal> |
| 120 | + </goals> |
| 121 | + <configuration> |
| 122 | + <outputDirectory>${current-release-directory}</outputDirectory> |
| 123 | + <resources> |
| 124 | + <resource> |
| 125 | + <directory>${project.build.directory}/repository</directory> |
| 126 | + </resource> |
| 127 | + </resources> |
| 128 | + </configuration> |
| 129 | + </execution> |
| 130 | + </executions> |
| 131 | + </plugin> |
| 132 | + <plugin> |
| 133 | + <groupId>org.eclipse.tycho.extras</groupId> |
| 134 | + <artifactId>tycho-eclipserun-plugin</artifactId> |
| 135 | + <version>${tycho-version}</version> |
| 136 | + <configuration> |
| 137 | + <repositories> |
| 138 | + <repository> |
| 139 | + <id>juno</id> |
| 140 | + <layout>p2</layout> |
| 141 | + <url>https://download.eclipse.org/releases/juno</url> |
| 142 | + </repository> |
| 143 | + </repositories> |
| 144 | + <dependencies> |
| 145 | + <dependency> |
| 146 | + <artifactId>org.eclipse.ant.core</artifactId> |
| 147 | + <type>eclipse-plugin</type> |
| 148 | + </dependency> |
| 149 | + <dependency> |
| 150 | + <artifactId>org.apache.ant</artifactId> |
| 151 | + <type>eclipse-plugin</type> |
| 152 | + </dependency> |
| 153 | + <dependency> |
| 154 | + <artifactId>org.eclipse.equinox.p2.repository.tools</artifactId> |
| 155 | + <type>eclipse-plugin</type> |
| 156 | + </dependency> |
| 157 | + <dependency> |
| 158 | + <artifactId>org.eclipse.equinox.p2.core.feature</artifactId> |
| 159 | + <type>eclipse-feature</type> |
| 160 | + </dependency> |
| 161 | + <dependency> |
| 162 | + <artifactId>org.eclipse.equinox.p2.extras.feature</artifactId> |
| 163 | + <type>eclipse-feature</type> |
| 164 | + </dependency> |
| 165 | + <dependency> |
| 166 | + <artifactId>org.eclipse.equinox.ds</artifactId> |
| 167 | + <type>eclipse-plugin</type> |
| 168 | + </dependency> |
| 169 | + </dependencies> |
| 170 | + </configuration> |
| 171 | + <executions> |
| 172 | + <!-- add our new child repository --> |
| 173 | + <execution> |
| 174 | + <id>add-p2-composite-repository</id> |
| 175 | + <phase>package</phase> |
| 176 | + <goals> |
| 177 | + <goal>eclipse-run</goal> |
50 | 178 | </goals> |
51 | 179 | <configuration> |
52 | | - <bintrayPackage>update-site-archive</bintrayPackage> |
53 | | - <bintrayVersion>${unqualifiedVersion}</bintrayVersion> |
54 | | - <sourceFolder>${project.build.directory}/</sourceFolder> |
55 | | - <uploadRegex>.*\Qnet.sf.eclipsecs-updatesite_\E.*\.zip</uploadRegex> |
56 | | - <targetFolder>update-site-archive</targetFolder> |
57 | | - <performCleanup>true</performCleanup> |
58 | | - <cleanupRegex>^.*\Qnet.sf.eclipsecs-updatesite_${unqualifiedVersion}\E.*\.zip$</cleanupRegex> |
| 180 | + <applicationsArgs> |
| 181 | + <args>-application</args> |
| 182 | + <args>org.eclipse.ant.core.antRunner</args> |
| 183 | + <args>-buildfile</args> |
| 184 | + <args>packaging-p2composite.ant</args> |
| 185 | + <args>p2.composite.add</args> |
| 186 | + <args>-Dsite.label="${site.label}"</args> |
| 187 | + <args>-Dcomposite.base.dir=${github-local-clone}</args> |
| 188 | + <args>-DunqualifiedVersion=${unqualifiedVersion}</args> |
| 189 | + <args>-DbuildQualifier=${buildQualifier}</args> |
| 190 | + <args>-DparsedVersion.majorVersion=${parsedVersion.majorVersion}</args> |
| 191 | + <args>-DparsedVersion.minorVersion=${parsedVersion.minorVersion}</args> |
| 192 | + </applicationsArgs> |
59 | 193 | </configuration> |
60 | 194 | </execution> |
61 | 195 | </executions> |
|
0 commit comments