Skip to content

Commit

Permalink
change:add gpg sign
Browse files Browse the repository at this point in the history
  • Loading branch information
Shawn authored and Shawn committed Mar 18, 2022
1 parent 138cf3b commit 1b63244
Show file tree
Hide file tree
Showing 4 changed files with 55 additions and 7 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/maven-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,12 @@ jobs:
distribution: 'temurin'
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
settings-path: ${{ github.workspace }} # location for the settings.xml file

- name: Build with Maven
run: mvn -B package --file pom.xml

- name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@v4
with:
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
passphrase: ${{ secrets.PASSPHRASE }}
- name: Publish to GitHub Packages Apache Maven
run: mvn deploy -s $GITHUB_WORKSPACE/settings.xml
env:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
</dependency>
```

3. 具体用法参考 https://github.com/uduncloud/java-wallet-sdk/blob/main/src/test/java/UdunclientDemo.java
3. 具体用法参考 https://github.com/uduncloud/java-wallet-sdk/blob/main/src/test/java/UdunClientDemo.java
4. 所有支持方法参考 https://github.com/uduncloud/java-wallet-sdk/blob/main/src/main/java/com/udun/sdk/client/UdunApi.java

## 三、关于回调
Expand Down
48 changes: 47 additions & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>com.uduncloud</groupId>
<artifactId>udun-sdk</artifactId>
<version>2.1.0</version>
<version>2.1.1</version>

<dependencies>
<dependency>
Expand All @@ -19,13 +19,59 @@
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
</plugin>
<!-- Source -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.2.0</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>jar-no-fork</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.6</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<scm>
<url>https://github.com/uduncloud/udun-sdk-java</url>
</scm>

<distributionManagement>
<repository>
<id>github</id>
<name>GitHub Uduncloud Apache Maven Packages</name>
<url>https://maven.pkg.github.com/uduncloud/udun-sdk-java</url>
</repository>
<!--<repository>
<id>ossrh</id>
<name>Maven Central Packages</name>
<url>https://s01.oss.sonatype.org/content/repositories/releases/</url>
</repository>-->

</distributionManagement>

</project>
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import java.math.BigDecimal;
import java.util.List;

public class UdunclientDemo {
public class UdunClientDemo {
public static void main(String[] args) {
//初始化
UdunClient udunClient = new UdunClient("https://hd03-node.uduncloud.com",
Expand Down

0 comments on commit 1b63244

Please sign in to comment.