-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
112 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,17 @@ | ||
name: release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
release-version: | ||
description: 'Version being released' | ||
required: true | ||
branch: | ||
description: 'Branch to release from' | ||
required: true | ||
default: 'main' | ||
push: | ||
# TODO: revert these changes, just need to publish! | ||
# workflow_dispatch: | ||
# inputs: | ||
# release-version: | ||
# description: 'Version being released' | ||
# required: true | ||
# branch: | ||
# description: 'Branch to release from' | ||
# required: true | ||
# default: 'main' | ||
|
||
permissions: | ||
contents: write | ||
|
@@ -23,8 +25,6 @@ jobs: | |
- name: Checkout | ||
uses: actions/checkout@v3 | ||
|
||
# Configure build steps as you'd normally do | ||
|
||
- name: Setup Java | ||
uses: actions/setup-java@v3 | ||
with: | ||
|
@@ -36,36 +36,49 @@ jobs: | |
gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
gpg-passphrase: MAVEN_GPG_PASSPHRASE | ||
|
||
- id: install-secret-key | ||
name: Install gpg secret key | ||
run: | | ||
cat <(echo -e "${{ secrets.GPG_PRIVATE_KEY }}") | gpg --batch --import | ||
gpg --list-secret-keys --keyid-format LONG | ||
- name: Compile | ||
run: mvn clean install -DskipTests=true | ||
|
||
- name: Setup Git | ||
run: | | ||
git config user.name "Chicory BOT" | ||
git config user.email "[email protected]" | ||
- name: Set the version | ||
run: | | ||
mvn versions:set -DgenerateBackupPoms=false -DnewVersion=${{ github.event.inputs.release-version }} | ||
git add . | ||
git commit -m "Release version update ${{ github.event.inputs.release-version }}" | ||
git push | ||
git tag ${{ github.event.inputs.release-version }} | ||
git push origin ${{ github.event.inputs.release-version }} | ||
env: | ||
GITHUB_TOKEN: ${{secrets.GH_TOKEN}} | ||
# - name: Set the version | ||
# run: | | ||
# mvn versions:set -DgenerateBackupPoms=false -DnewVersion=${{ github.event.inputs.release-version }} | ||
# git add . | ||
# git commit -m "Release version update ${{ github.event.inputs.release-version }}" | ||
# git push | ||
# git tag ${{ github.event.inputs.release-version }} | ||
# git push origin ${{ github.event.inputs.release-version }} | ||
# env: | ||
# GITHUB_TOKEN: ${{secrets.GH_TOKEN}} | ||
|
||
- name: Release to Maven Central | ||
run: | | ||
export GPG_TTY=$(tty) | ||
mvn clean install source:jar javadoc:jar deploy --batch-mode -Prelease -DskipTests -X | ||
run: mvn --batch-mode clean deploy -Prelease -DskipTests=true -X | ||
env: | ||
MAVEN_USERNAME: ${{ secrets.SONATYPE_USERNAME }} | ||
MAVEN_CENTRAL_TOKEN: ${{ secrets.SONATYPE_PASSWORD }} | ||
MAVEN_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }} | ||
|
||
- name: Back to Snapshot | ||
run: | | ||
mvn versions:set -DgenerateBackupPoms=false -DnewVersion=999-SNAPSHOT | ||
git add . | ||
git commit -m "Snapshot version update" | ||
git push | ||
env: | ||
GITHUB_TOKEN: ${{secrets.GH_TOKEN}} | ||
# - name: Release | ||
# uses: softprops/action-gh-release@de2c0eb89ae2a093876385947365aca7b0e5f844 # v1 | ||
# with: | ||
# tag_name: ${{ github.event.inputs.release-version }} | ||
# token: ${{secrets.GH_TOKEN}} | ||
|
||
# - name: Back to Snapshot | ||
# run: | | ||
# mvn versions:set -DgenerateBackupPoms=false -DnewVersion=999-SNAPSHOT | ||
# git add . | ||
# git commit -m "Snapshot version update" | ||
# git push | ||
# env: | ||
# GITHUB_TOKEN: ${{secrets.GH_TOKEN}} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,6 +10,11 @@ | |
<description>Native JVM WebAssembly runtime</description> | ||
<url>https://github.com/dylibso/chicory</url> | ||
|
||
<organization> | ||
<name>Dylibso, Inc.</name> | ||
<url>https://dylibso.com</url> | ||
</organization> | ||
|
||
<licenses> | ||
<license> | ||
<name>Apache-2.0</name> | ||
|
@@ -25,9 +30,6 @@ | |
<email>[email protected]</email> | ||
<organization>Dylibso, Inc.</organization> | ||
<organizationUrl>https://dylibso.com</organizationUrl> | ||
<roles> | ||
<role>Maintainer</role> | ||
</roles> | ||
</developer> | ||
</developers> | ||
|
||
|
@@ -51,6 +53,14 @@ | |
<url>https://github.com/dylibso/chicory/issues</url> | ||
</issueManagement> | ||
|
||
<distributionManagement> | ||
<repository> | ||
<id>ossrh</id> | ||
<name>Central Repository OSSRH</name> | ||
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url> | ||
</repository> | ||
</distributionManagement> | ||
|
||
<properties> | ||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> | ||
|
@@ -113,7 +123,6 @@ | |
</dependencyManagement> | ||
|
||
<build> | ||
|
||
<pluginManagement> | ||
<plugins> | ||
<plugin> | ||
|
@@ -204,6 +213,36 @@ | |
</systemPropertyVariables> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-javadoc-plugin</artifactId> | ||
<version>${maven-javadoc-plugin.version}</version> | ||
<configuration> | ||
<doclint>none</doclint> | ||
<source>1.8</source> | ||
</configuration> | ||
<executions> | ||
<execution> | ||
<id>attach-javadocs</id> | ||
<goals> | ||
<goal>jar</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-source-plugin</artifactId> | ||
<version>${maven-source-plugin.version}</version> | ||
<executions> | ||
<execution> | ||
<id>attach-sources</id> | ||
<goals> | ||
<goal>jar</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
<plugin> | ||
<groupId>com.diffplug.spotless</groupId> | ||
<artifactId>spotless-maven-plugin</artifactId> | ||
|
@@ -267,73 +306,36 @@ | |
</distributionManagement> | ||
<build> | ||
<plugins> | ||
<plugin> | ||
<groupId>org.sonatype.plugins</groupId> | ||
<artifactId>nexus-staging-maven-plugin</artifactId> | ||
<extensions>true</extensions> | ||
<configuration> | ||
<serverId>ossrh</serverId> | ||
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl> | ||
<autoReleaseAfterClose>true</autoReleaseAfterClose> | ||
</configuration> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-gpg-plugin</artifactId> | ||
<version>3.1.0</version> | ||
<version>${maven-gpg-plugin.version}</version> | ||
<configuration> | ||
<gpgArguments> | ||
<arg>--pinentry-mode</arg> | ||
<arg>loopback</arg> | ||
</gpgArguments> | ||
</configuration> | ||
<executions> | ||
<execution> | ||
<id>sign-artifacts</id> | ||
<goals> | ||
<goal>sign</goal> | ||
</goals> | ||
<phase>verify</phase> | ||
<configuration> | ||
<!-- Prevent `gpg` from using pinentry programs --> | ||
<gpgArguments> | ||
<arg>--pinentry-mode</arg> | ||
<arg>loopback</arg> | ||
</gpgArguments> | ||
</configuration> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-source-plugin</artifactId> | ||
<executions> | ||
<execution> | ||
<id>attach-sources</id> | ||
<goals> | ||
<goal>jar-no-fork</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-javadoc-plugin</artifactId> | ||
<groupId>org.sonatype.plugins</groupId> | ||
<artifactId>nexus-staging-maven-plugin</artifactId> | ||
<version>${nexus-staging-maven-plugin.version}</version> | ||
<extensions>true</extensions> | ||
<configuration> | ||
<additionalDependencies> | ||
<additionalDependency> | ||
<groupId>jakarta.annotation</groupId> | ||
<artifactId>jakarta.annotation-api</artifactId> | ||
<version>${annotation-api.version}</version> | ||
</additionalDependency> | ||
</additionalDependencies> | ||
<failOnError>false</failOnError> | ||
<failOnWarnings>false</failOnWarnings> | ||
<source>${maven.compiler.source}</source> | ||
<additionalOptions>-Xdoclint:none</additionalOptions> | ||
<serverId>ossrh</serverId> | ||
<nexusUrl>https://s01.oss.sonatype.org/</nexusUrl> | ||
<autoReleaseAfterClose>true</autoReleaseAfterClose> | ||
</configuration> | ||
<executions> | ||
<execution> | ||
<id>attach-javadocs</id> | ||
<goals> | ||
<goal>jar</goal> | ||
</goals> | ||
</execution> | ||
</executions> | ||
</plugin> | ||
</plugins> | ||
</build> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters