You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

pom.xml 7.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  3. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  4. <modelVersion>4.0.0</modelVersion>
  5. <parent>
  6. <groupId>com.vaadin</groupId>
  7. <artifactId>vaadin-root</artifactId>
  8. <version>8.10-SNAPSHOT</version>
  9. </parent>
  10. <artifactId>vaadin-push</artifactId>
  11. <name>vaadin-push</name>
  12. <packaging>jar</packaging>
  13. <properties>
  14. </properties>
  15. <url>https://vaadin.com/</url>
  16. <description>Vaadin server push support</description>
  17. <dependencies>
  18. <!-- Atmosphere -->
  19. <dependency>
  20. <groupId>com.vaadin.external.atmosphere</groupId>
  21. <artifactId>atmosphere-runtime</artifactId>
  22. </dependency>
  23. <dependency>
  24. <groupId>com.vaadin.external.atmosphere.client</groupId>
  25. <artifactId>javascript</artifactId>
  26. <type>war</type>
  27. <scope>provided</scope>
  28. </dependency>
  29. <dependency>
  30. <groupId>${project.groupId}</groupId>
  31. <artifactId>vaadin-shared</artifactId>
  32. <version>${project.version}</version>
  33. <scope>provided</scope>
  34. </dependency>
  35. <dependency>
  36. <groupId>org.osgi</groupId>
  37. <artifactId>osgi.core</artifactId>
  38. </dependency>
  39. <dependency>
  40. <groupId>org.osgi</groupId>
  41. <artifactId>osgi.cmpn</artifactId>
  42. </dependency>
  43. </dependencies>
  44. <build>
  45. <plugins>
  46. <plugin>
  47. <artifactId>maven-antrun-plugin</artifactId>
  48. <executions>
  49. <execution>
  50. <id>default-cli</id>
  51. <phase>generate-resources</phase>
  52. <goals>
  53. <goal>run</goal>
  54. </goals>
  55. <!-- <inherited>false</inherited> -->
  56. <configuration>
  57. <target>
  58. <property name="javascript.unpack"
  59. location="${project.build.directory}/temp" />
  60. <property name="vaadinPush.js"
  61. location="${project.build.outputDirectory}/VAADIN/vaadinPush.debug.js" />
  62. <property name="templates.dir"
  63. location="${project.build.sourceDirectory}/../templates" />
  64. <!-- Unzip to temp dir -->
  65. <unzip
  66. src="${maven.dependency.com.vaadin.external.atmosphere.client.javascript.war.path}"
  67. dest="${javascript.unpack}">
  68. <patternset>
  69. <include name="**/atmosphere.js" />
  70. </patternset>
  71. <mapper type="flatten" />
  72. </unzip>
  73. <loadfile
  74. srcfile="${javascript.unpack}/atmosphere.js"
  75. property="atmosphere.js.contents" />
  76. <loadfile
  77. srcfile="${templates.dir}/vaadinPush.js.tpl"
  78. property="vaadinPush.js.contents">
  79. <filterchain>
  80. <replacetokens
  81. begintoken="@" endtoken="@">
  82. <token key="atmosphere.js"
  83. value="${atmosphere.js.contents}" />
  84. </replacetokens>
  85. </filterchain>
  86. </loadfile>
  87. <!-- Non-obfuscated version for debugging -->
  88. <echo file="${vaadinPush.js}">${vaadinPush.js.contents}</echo>
  89. </target>
  90. </configuration>
  91. </execution>
  92. <execution>
  93. <id>compresspush</id>
  94. <phase>compile</phase>
  95. <goals>
  96. <goal>run</goal>
  97. </goals>
  98. <configuration>
  99. <target>
  100. <property name="vaadinPush.debug.js"
  101. location="${project.build.outputDirectory}/VAADIN/vaadinPush.debug.js" />
  102. <property name="vaadinPush-min.js"
  103. location="${project.build.outputDirectory}/VAADIN/vaadinPush.debug-min.js" />
  104. <property name="vaadinPush.js"
  105. location="${project.build.outputDirectory}/VAADIN/vaadinPush.js" />
  106. <move file="${vaadinPush-min.js}"
  107. tofile="${vaadinPush.js}" />
  108. <!-- Gzipped versions -->
  109. <gzip src="${vaadinPush.debug.js}"
  110. destfile="${vaadinPush.debug.js}.gz" />
  111. <gzip src="${vaadinPush.js}"
  112. destfile="${vaadinPush.js}.gz" />
  113. </target>
  114. </configuration>
  115. </execution>
  116. </executions>
  117. </plugin>
  118. <plugin>
  119. <groupId>net.alchim31.maven</groupId>
  120. <artifactId>yuicompressor-maven-plugin</artifactId>
  121. <version>1.5.1</version>
  122. <executions>
  123. <execution>
  124. <id>minifyjs</id>
  125. <phase>process-resources</phase>
  126. <goals>
  127. <goal>compress</goal>
  128. </goals>
  129. </execution>
  130. </executions>
  131. <configuration>
  132. <sourceDirectory>${project.build.outputDirectory}/VAADIN</sourceDirectory>
  133. <includes>
  134. <include>vaadinPush.debug.js</include>
  135. </includes>
  136. <outputDirectory>${project.build.outputDirectory}/VAADIN</outputDirectory>
  137. </configuration>
  138. </plugin>
  139. <plugin>
  140. <groupId>biz.aQute.bnd</groupId>
  141. <artifactId>bnd-maven-plugin</artifactId>
  142. </plugin>
  143. <plugin>
  144. <groupId>org.apache.maven.plugins</groupId>
  145. <artifactId>maven-jar-plugin</artifactId>
  146. <configuration>
  147. <archive>
  148. <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
  149. <index>false</index>
  150. <manifest>
  151. <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
  152. </manifest>
  153. </archive>
  154. </configuration>
  155. </plugin>
  156. </plugins>
  157. </build>
  158. </project>