easy-requester
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency> <groupId>io.github.lookoutldz</groupId> <artifactId>easy-requester</artifactId> <version>2.3.3</version> </dependency>
<?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" 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> <groupId>io.github.lookoutldz</groupId> <artifactId>easy-requester</artifactId> <version>2.3.3</version> <name>easy-requester</name> <description>一款简单优雅的HTTP请求器!A simple and elegant HTTP request tool!</description> <url>https://github.com/lookoutldz/easy-requester</url> <licenses> <license> <name>MIT License</name> <url>http://www.opensource.org/licenses/mit-license.php</url> </license> </licenses> <developers> <developer> <id>looko</id> <name>looko</name> <email>lookoutldz@outlook.com</email> <roles> <role>Project Manager</role> <role>Architect</role> </roles> </developer> </developers> <scm> <connection>https://github.com/lookoutldz/easy-requester.git</connection> <developerConnection>scm:git:ssh://git@github.com:lookoutldz/easy-requester.git</developerConnection> <url>https://github.com/lookoutldz/easy-requester</url> </scm> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <kotlin.code.style>official</kotlin.code.style> <kotlin.compiler.jvmTarget>21</kotlin.compiler.jvmTarget> <kotlin.version>2.1.21</kotlin.version> </properties> <repositories> <repository> <id>mavenCentral</id> <url>https://repo1.maven.org/maven2/</url> </repository> </repositories> <dependencies> <!-- kotlin --> <dependency> <groupId>org.jetbrains.kotlin</groupId> <artifactId>kotlin-stdlib-jdk8</artifactId> <version>${kotlin.version}</version> </dependency> <!-- jackson-module-kotlin --> <dependency> <groupId>com.fasterxml.jackson.module</groupId> <artifactId>jackson-module-kotlin</artifactId> <version>2.18.4</version> </dependency> <!-- jackson-datatype-jsr310 to deal with java datetime --> <dependency> <groupId>com.fasterxml.jackson.datatype</groupId> <artifactId>jackson-datatype-jsr310</artifactId> <version>2.18.4</version> </dependency> <!-- okhttp3 --> <dependency> <groupId>com.squareup.okhttp3</groupId> <artifactId>okhttp</artifactId> <version>4.12.0</version> </dependency> <!-- test --> <dependency> <groupId>org.jetbrains.kotlin</groupId> <artifactId>kotlin-test-junit5</artifactId> <version>2.1.21</version> <scope>test</scope> </dependency> <dependency> <groupId>org.junit.jupiter</groupId> <artifactId>junit-jupiter</artifactId> <version>5.10.0</version> <scope>test</scope> </dependency> <dependency> <groupId>org.jetbrains.kotlin</groupId> <artifactId>kotlin-test</artifactId> <version>${kotlin.version}</version> <scope>test</scope> </dependency> </dependencies> <build> <sourceDirectory>src/main/kotlin</sourceDirectory> <testSourceDirectory>src/test/kotlin</testSourceDirectory> <!-- 添加以下配置支持Java测试 --> <plugins> <!-- 添加Maven编译插件支持Java --> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>build-helper-maven-plugin</artifactId> <version>3.6.0</version> <executions> <execution> <id>add-test-source</id> <phase>generate-test-sources</phase> <goals> <goal>add-test-source</goal> </goals> <configuration> <sources> <source>src/test/java</source> </sources> </configuration> </execution> </executions> </plugin> <!-- 现有的kotlin-maven-plugin保持不变 --> <plugin> <groupId>org.jetbrains.kotlin</groupId> <artifactId>kotlin-maven-plugin</artifactId> <version>${kotlin.version}</version> <executions> <execution> <id>compile</id> <phase>process-sources</phase> <goals> <goal>compile</goal> </goals> </execution> <execution> <id>test-compile</id> <phase>process-test-sources</phase> <goals> <goal>test-compile</goal> </goals> <configuration> <sourceDirs> <sourceDir>${project.basedir}/src/test/kotlin</sourceDir> <sourceDir>${project.basedir}/src/test/java</sourceDir> </sourceDirs> </configuration> </execution> </executions> <configuration> <jvmTarget>21</jvmTarget> </configuration> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-surefire-plugin</artifactId> <version>3.5.3</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-failsafe-plugin</artifactId> <version>3.5.3</version> </plugin> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>exec-maven-plugin</artifactId> <version>3.5.0</version> <configuration> <mainClass>MainKt</mainClass> </configuration> </plugin> <!-- Java 编译器,执行 Java Test 所需 - 在 Kotlin 之后执行 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.14.0</version> <executions> <execution> <id>default-compile</id> <phase>none</phase> </execution> <execution> <id>default-testCompile</id> <phase>none</phase> </execution> <execution> <id>java-compile</id> <phase>compile</phase> <goals> <goal>compile</goal> </goals> </execution> <execution> <id>java-test-compile</id> <phase>test-compile</phase> <goals> <goal>testCompile</goal> </goals> </execution> </executions> <configuration> <source>21</source> <target>21</target> </configuration> </plugin> </plugins> </build> <profiles> <!-- Maven Central profile --> <profile> <id>release</id> <build> <plugins> <!-- central发布插件 --> <plugin> <groupId>org.sonatype.central</groupId> <artifactId>central-publishing-maven-plugin</artifactId> <version>0.7.0</version> <extensions>true</extensions> <configuration> <!-- publishingServerId 是在 settings.xml中配置的 server 认证信息 --> <publishingServerId>lookoutldz</publishingServerId> <!-- autoPublish 是自动发布,而不是手动发布, 手动发布需要登录 https://central.sonatype.com 后切换到Deployment --> <autoPublish>true</autoPublish> <!-- waitUntil 配置为 published 是等待发布完成,因为发布完成的时间比较长,所以可以不加这个参数 --> <waitUntil>published</waitUntil> <!-- deploymentName 是发布到中央仓库的名称 --> <deploymentName>${project.groupId}:${project.artifactId}:${project.version}</deploymentName> </configuration> </plugin> <!-- source源码插件 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-source-plugin</artifactId> <version>3.3.1</version> <executions> <execution> <id>attach-sources</id> <goals> <goal>jar-no-fork</goal> </goals> </execution> </executions> </plugin> <!-- javadoc插件 --> <plugin> <groupId>org.jetbrains.dokka</groupId> <artifactId>dokka-maven-plugin</artifactId> <version>1.9.20</version> <executions> <execution> <phase>prepare-package</phase> <goals> <goal>javadocJar</goal> </goals> </execution> </executions> <configuration> <sourceDirectories> <dir>${project.basedir}/src/main/kotlin</dir> </sourceDirectories> </configuration> </plugin> <!-- GPG 签名插件 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-gpg-plugin</artifactId> <version>3.2.7</version> <configuration> <!--Mac GPG--> <!-- <executable>/usr/local/bin/gpg</executable>--> <!--Ubuntu GPG--> <executable>/usr/bin/gpg</executable> <keyname>io.github.lookoutldz</keyname> </configuration> <executions> <execution> <id>sign-artifacts</id> <phase>verify</phase> <goals> <goal>sign</goal> </goals> </execution> </executions> </plugin> </plugins> </build> </profile> <!-- GitHub Packages profile --> <profile> <id>github</id> <distributionManagement> <repository> <id>github</id> <name>GitHub Packages</name> <url>https://maven.pkg.github.com/lookoutldz/easy-requester</url> </repository> </distributionManagement> <build> <plugins> <!-- 源码插件 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-source-plugin</artifactId> <version>3.3.1</version> <executions> <execution> <id>attach-sources</id> <goals> <goal>jar-no-fork</goal> </goals> </execution> </executions> </plugin> <!-- Javadoc 插件 --> <plugin> <groupId>org.jetbrains.dokka</groupId> <artifactId>dokka-maven-plugin</artifactId> <version>1.9.20</version> <executions> <execution> <phase>prepare-package</phase> <goals> <goal>javadocJar</goal> </goals> </execution> </executions> <configuration> <sourceDirectories> <dir>${project.basedir}/src/main/kotlin</dir> </sourceDirectories> </configuration> </plugin> </plugins> </build> </profile> <!-- Local Maven Repository profile --> <profile> <id>local</id> <build> <plugins> <!-- 源码插件 --> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-source-plugin</artifactId> <version>3.3.1</version> <executions> <execution> <id>attach-sources</id> <goals> <goal>jar-no-fork</goal> </goals> </execution> </executions> </plugin> <!-- Javadoc 插件 --> <plugin> <groupId>org.jetbrains.dokka</groupId> <artifactId>dokka-maven-plugin</artifactId> <version>1.9.20</version> <executions> <execution> <phase>prepare-package</phase> <goals> <goal>javadocJar</goal> </goals> </execution> </executions> <configuration> <sourceDirectories> <dir>${project.basedir}/src/main/kotlin</dir> </sourceDirectories> </configuration> </plugin> </plugins> </build> </profile> </profiles> </project>