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 12KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366
  1. <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/maven-v4_0_0.xsd">
  2. <modelVersion>4.0.0</modelVersion>
  3. <parent>
  4. <groupId>org.sonarsource.parent</groupId>
  5. <artifactId>parent</artifactId>
  6. <version>71.0.0.1292</version>
  7. </parent>
  8. <groupId>org.sonarsource.scanner.cli</groupId>
  9. <artifactId>sonar-scanner-cli</artifactId>
  10. <version>6.0-SNAPSHOT</version>
  11. <packaging>jar</packaging>
  12. <name>SonarScanner CLI</name>
  13. <url>https://docs.sonarsource.com/sonarqube/latest/analyzing-source-code/scanners/sonarscanner/</url>
  14. <inceptionYear>2011</inceptionYear>
  15. <organization>
  16. <name>SonarSource</name>
  17. <url>https://www.sonarsource.com</url>
  18. </organization>
  19. <licenses>
  20. <license>
  21. <name>GNU LGPL 3</name>
  22. <url>https://www.gnu.org/licenses/lgpl.txt</url>
  23. <distribution>repo</distribution>
  24. </license>
  25. </licenses>
  26. <scm>
  27. <connection>scm:git:git@github.com:SonarSource/sonar-scanner-cli.git</connection>
  28. <developerConnection>scm:git:git@github.com:SonarSource/sonar-scanner-cli.git</developerConnection>
  29. <url>https://github.com/SonarSource/sonar-scanner-cli</url>
  30. <tag>HEAD</tag>
  31. </scm>
  32. <issueManagement>
  33. <system>JIRA</system>
  34. <url>https://jira.sonarsource.com/browse/SCANCLI</url>
  35. </issueManagement>
  36. <ciManagement>
  37. <system>cirrus-ci</system>
  38. <url>https://cirrus-ci.com/github/SonarSource/sonar-scanner-cli</url>
  39. </ciManagement>
  40. <properties>
  41. <maven.test.redirectTestOutputToFile>true</maven.test.redirectTestOutputToFile>
  42. <!-- used for deployment to SonarSource Artifactory -->
  43. <gitRepositoryName>sonar-scanner-cli</gitRepositoryName>
  44. <!-- configuration for assembly of distributions -->
  45. <unpack.dir>${project.build.directory}/unpack</unpack.dir>
  46. <scanner.jar>${project.build.finalName}.jar</scanner.jar>
  47. <jre.dirname.linux>jdk-17.0.11+9-jre</jre.dirname.linux>
  48. <jre.dirname.windows>jdk-17.0.11+9-jre</jre.dirname.windows>
  49. <jre.dirname.macosx>jdk-17.0.11+9-jre/Contents/Home</jre.dirname.macosx>
  50. <!-- Release: enable publication to Bintray -->
  51. <artifactsToPublish>${project.groupId}:${project.artifactId}:zip,${project.groupId}:${project.artifactId}:zip:linux,${project.groupId}:${project.artifactId}:zip:windows,${project.groupId}:${project.artifactId}:zip:macosx,${project.groupId}:${project.artifactId}:json:cyclonedx</artifactsToPublish>
  52. <maven.compiler.release>17</maven.compiler.release>
  53. </properties>
  54. <dependencies>
  55. <dependency>
  56. <groupId>org.sonarsource.scanner.lib</groupId>
  57. <artifactId>sonar-scanner-java-library</artifactId>
  58. <version>3.0.0.114</version>
  59. </dependency>
  60. <dependency>
  61. <groupId>com.google.code.findbugs</groupId>
  62. <artifactId>jsr305</artifactId>
  63. <version>3.0.2</version>
  64. <scope>provided</scope>
  65. </dependency>
  66. <!-- Unit tests -->
  67. <dependency>
  68. <groupId>org.junit.jupiter</groupId>
  69. <artifactId>junit-jupiter-engine</artifactId>
  70. <version>5.10.1</version>
  71. <scope>test</scope>
  72. </dependency>
  73. <dependency>
  74. <groupId>org.assertj</groupId>
  75. <artifactId>assertj-core</artifactId>
  76. <version>3.24.2</version>
  77. <scope>test</scope>
  78. </dependency>
  79. <dependency>
  80. <groupId>org.mockito</groupId>
  81. <artifactId>mockito-core</artifactId>
  82. <version>5.10.0</version>
  83. <scope>test</scope>
  84. </dependency>
  85. </dependencies>
  86. <build>
  87. <resources>
  88. <resource>
  89. <directory>src/main/resources</directory>
  90. <filtering>true</filtering>
  91. </resource>
  92. </resources>
  93. <pluginManagement>
  94. <plugins>
  95. <plugin>
  96. <groupId>com.googlecode.maven-download-plugin</groupId>
  97. <artifactId>download-maven-plugin</artifactId>
  98. <version>1.9.0</version>
  99. </plugin>
  100. </plugins>
  101. </pluginManagement>
  102. <plugins>
  103. <plugin>
  104. <groupId>org.apache.maven.plugins</groupId>
  105. <artifactId>maven-jar-plugin</artifactId>
  106. <configuration>
  107. <archive>
  108. <manifest>
  109. <addClasspath>false</addClasspath>
  110. <mainClass>org.sonarsource.scanner.cli.Main</mainClass>
  111. </manifest>
  112. </archive>
  113. </configuration>
  114. </plugin>
  115. <plugin>
  116. <groupId>org.apache.maven.plugins</groupId>
  117. <artifactId>maven-shade-plugin</artifactId>
  118. <version>3.5.1</version>
  119. <executions>
  120. <execution>
  121. <phase>package</phase>
  122. <goals>
  123. <goal>shade</goal>
  124. </goals>
  125. <configuration>
  126. <createDependencyReducedPom>true</createDependencyReducedPom>
  127. <minimizeJar>true</minimizeJar>
  128. </configuration>
  129. </execution>
  130. </executions>
  131. </plugin>
  132. <plugin>
  133. <groupId>org.apache.maven.plugins</groupId>
  134. <artifactId>maven-assembly-plugin</artifactId>
  135. <executions>
  136. <execution>
  137. <id>cli</id>
  138. <phase>package</phase>
  139. <goals>
  140. <goal>single</goal>
  141. </goals>
  142. <configuration>
  143. <finalName>sonar-scanner-${project.version}</finalName>
  144. <appendAssemblyId>false</appendAssemblyId>
  145. <escapeString>\</escapeString>
  146. <descriptors>
  147. <descriptor>src/main/assembly/noarch.xml</descriptor>
  148. </descriptors>
  149. <filters>
  150. <filter>src/main/assembly/filter-noarch.properties</filter>
  151. </filters>
  152. </configuration>
  153. </execution>
  154. </executions>
  155. </plugin>
  156. <plugin>
  157. <groupId>org.apache.maven.plugins</groupId>
  158. <artifactId>maven-enforcer-plugin</artifactId>
  159. <executions>
  160. <execution>
  161. <id>enforce-distribution-size</id>
  162. <goals>
  163. <goal>enforce</goal>
  164. </goals>
  165. <phase>verify</phase>
  166. <configuration>
  167. <rules>
  168. <requireFilesSize>
  169. <minsize>3400000</minsize>
  170. <maxsize>3500000</maxsize>
  171. <files>
  172. <file>${project.build.directory}/sonar-scanner-${project.version}.zip</file>
  173. </files>
  174. </requireFilesSize>
  175. </rules>
  176. </configuration>
  177. </execution>
  178. </executions>
  179. </plugin>
  180. <plugin>
  181. <groupId>org.apache.maven.plugins</groupId>
  182. <artifactId>maven-javadoc-plugin</artifactId>
  183. <configuration>
  184. <source>17</source>
  185. </configuration>
  186. </plugin>
  187. <plugin>
  188. <groupId>org.cyclonedx</groupId>
  189. <artifactId>cyclonedx-maven-plugin</artifactId>
  190. <executions>
  191. <execution>
  192. <phase>package</phase>
  193. <goals>
  194. <goal>makeAggregateBom</goal>
  195. </goals>
  196. </execution>
  197. </executions>
  198. </plugin>
  199. </plugins>
  200. </build>
  201. <profiles>
  202. <profile>
  203. <id>dist-linux</id>
  204. <build>
  205. <plugins>
  206. <plugin>
  207. <groupId>com.googlecode.maven-download-plugin</groupId>
  208. <artifactId>download-maven-plugin</artifactId>
  209. <executions>
  210. <execution>
  211. <id>unpack-linux</id>
  212. <phase>package</phase>
  213. <goals>
  214. <goal>wget</goal>
  215. </goals>
  216. <configuration>
  217. <url>https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.11%2B9/OpenJDK17U-jre_x64_linux_hotspot_17.0.11_9.tar.gz</url>
  218. <unpack>true</unpack>
  219. <outputDirectory>${unpack.dir}/linux</outputDirectory>
  220. <sha256>bcb1b7b8ad68c93093f09b591b7cb17161d39891f7d29d33a586f5a328603707</sha256>
  221. </configuration>
  222. </execution>
  223. </executions>
  224. </plugin>
  225. <plugin>
  226. <artifactId>maven-assembly-plugin</artifactId>
  227. <executions>
  228. <execution>
  229. <id>assemble-linux</id>
  230. <phase>package</phase>
  231. <goals>
  232. <goal>single</goal>
  233. </goals>
  234. <configuration>
  235. <finalName>sonar-scanner-${project.version}</finalName>
  236. <escapeString>\</escapeString>
  237. <descriptors>
  238. <descriptor>src/main/assembly/dist-linux.xml</descriptor>
  239. </descriptors>
  240. <filters>
  241. <filter>src/main/assembly/filter-dist.properties</filter>
  242. </filters>
  243. </configuration>
  244. </execution>
  245. </executions>
  246. </plugin>
  247. </plugins>
  248. </build>
  249. </profile>
  250. <profile>
  251. <id>dist-windows</id>
  252. <build>
  253. <plugins>
  254. <plugin>
  255. <groupId>com.googlecode.maven-download-plugin</groupId>
  256. <artifactId>download-maven-plugin</artifactId>
  257. <executions>
  258. <execution>
  259. <id>unpack-windows</id>
  260. <phase>package</phase>
  261. <goals>
  262. <goal>wget</goal>
  263. </goals>
  264. <configuration>
  265. <url>https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.11%2B9/OpenJDK17U-jre_x64_windows_hotspot_17.0.11_9.zip</url>
  266. <unpack>true</unpack>
  267. <outputDirectory>${unpack.dir}/windows</outputDirectory>
  268. <sha256>4bafe2e94439c8193fc8c68247cb0dbaf4e80265b903288f63f128304f129bbe</sha256>
  269. </configuration>
  270. </execution>
  271. </executions>
  272. </plugin>
  273. <plugin>
  274. <artifactId>maven-assembly-plugin</artifactId>
  275. <executions>
  276. <execution>
  277. <id>assemble-windows</id>
  278. <phase>package</phase>
  279. <goals>
  280. <goal>single</goal>
  281. </goals>
  282. <configuration>
  283. <finalName>sonar-scanner-${project.version}</finalName>
  284. <escapeString>\</escapeString>
  285. <descriptors>
  286. <descriptor>src/main/assembly/dist-windows.xml</descriptor>
  287. </descriptors>
  288. <filters>
  289. <filter>src/main/assembly/filter-dist.properties</filter>
  290. </filters>
  291. </configuration>
  292. </execution>
  293. </executions>
  294. </plugin>
  295. </plugins>
  296. </build>
  297. </profile>
  298. <profile>
  299. <id>dist-macosx</id>
  300. <build>
  301. <plugins>
  302. <plugin>
  303. <groupId>com.googlecode.maven-download-plugin</groupId>
  304. <artifactId>download-maven-plugin</artifactId>
  305. <executions>
  306. <execution>
  307. <id>unpack-macosx</id>
  308. <phase>package</phase>
  309. <goals>
  310. <goal>wget</goal>
  311. </goals>
  312. <configuration>
  313. <url>https://github.com/adoptium/temurin17-binaries/releases/download/jdk-17.0.11%2B9/OpenJDK17U-jre_x64_mac_hotspot_17.0.11_9.tar.gz</url>
  314. <unpack>true</unpack>
  315. <outputDirectory>${unpack.dir}/macosx</outputDirectory>
  316. <sha256>232c40bebd6ddbb673862e86e7e6e09bcfe399e5a53c8a6b77bf1ceab8edefd0</sha256>
  317. </configuration>
  318. </execution>
  319. </executions>
  320. </plugin>
  321. <plugin>
  322. <artifactId>maven-assembly-plugin</artifactId>
  323. <executions>
  324. <execution>
  325. <id>assemble-macosx</id>
  326. <phase>package</phase>
  327. <goals>
  328. <goal>single</goal>
  329. </goals>
  330. <configuration>
  331. <finalName>sonar-scanner-${project.version}</finalName>
  332. <escapeString>\</escapeString>
  333. <descriptors>
  334. <descriptor>src/main/assembly/dist-macosx.xml</descriptor>
  335. </descriptors>
  336. <filters>
  337. <filter>src/main/assembly/filter-dist.properties</filter>
  338. </filters>
  339. </configuration>
  340. </execution>
  341. </executions>
  342. </plugin>
  343. </plugins>
  344. </build>
  345. </profile>
  346. </profiles>
  347. </project>