Skip to content

Commit

Permalink
release config
Browse files Browse the repository at this point in the history
  • Loading branch information
supervate committed Apr 30, 2024
1 parent 76a761b commit 7bf6bf6
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 37 deletions.
35 changes: 7 additions & 28 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
name: Release

# Run workflow on commits to the `main` branch
on:
create:
tags:
- '*'

env:
build-number: ${GITHUB_RUN_NUMBER}
release:
types: [published]

jobs:
release:
Expand All @@ -21,27 +16,11 @@ jobs:
distribution: 'adopt-hotspot'
java-version: '21'
cache: 'maven'
- name: Run Tests
run: make test
- name: Upload Agent Jar Artifact
uses: actions/upload-artifact@v3
with:
name: Package
path: target
retention-days: 1
- name: Automatic releases
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: "${{ secrets.ARTLIBS_TOKEN }}"
automatic_release_tag: "${{ github.run_number }}"
title: "Automated Build ${{ github.run_number }}"
prerelease: true
files: target/autotrace4j.jar
- name: Release Maven Central
uses: samuelmeuli/action-maven-publish@v1
uses: samuelmeuli/action-maven-publish@v1.4.0
with:
server_id: central
gpg_private_key: ${{ secrets.gpg_private_key }}
gpg_passphrase: ${{ secrets.gpg_passphrase }}
nexus_username: ${{ secrets.nexus_username }}
nexus_password: ${{ secrets.nexus_password }}
gpg_private_key: ${{ secrets.MAVEN_GPG_PRIVATE_KEY }}
gpg_passphrase: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
nexus_username: ${{ secrets.OSSRH_USERNAME }}
nexus_password: ${{ secrets.OSSRH_TOKEN }}
32 changes: 23 additions & 9 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,22 @@
<groupId>io.github.vt</groupId>
<artifactId>v-log</artifactId>
<version>1.0.0</version>
<url>https://github.com/supervate/V-Log</url>
<description>V-Log is a simple logging library for Java.</description>

<licenses>
<license>
<name>The Apache License, Version 2.0</name>
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
</license>
</licenses>

<developers>
<developer>
<id>supervate</id>
<name>supervate</name>
</developer>
</developers>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down Expand Up @@ -104,7 +120,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>1.5</version>
<version>1.6</version>
<executions>
<execution>
<id>sign-artifacts</id>
Expand All @@ -123,16 +139,14 @@
</executions>
</plugin>
<plugin>
<groupId>org.sonatype.central</groupId>
<artifactId>central-publishing-maven-plugin</artifactId>
<version>0.4.0</version>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>1.6.13</version>
<extensions>true</extensions>
<configuration>
<publishingServerId>central</publishingServerId>
<tokenAuth>true</tokenAuth>
<!--<waitUntil>published</waitUntil>
<waitMaxTime>1800</waitMaxTime>-->
<autoPublish>true</autoPublish>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>false</autoReleaseAfterClose>
</configuration>
</plugin>
</plugins>
Expand Down

0 comments on commit 7bf6bf6

Please sign in to comment.