-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: introduce release-please process (#34)
Signed-off-by: Sebastian Becker <[email protected]>
- Loading branch information
Showing
10 changed files
with
156 additions
and
182 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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,5 +1,5 @@ | ||
# | ||
# Copyright (c) 2021 - for information on the respective copyright owner | ||
# Copyright (c) 2021-2023 - for information on the respective copyright owner | ||
# see the NOTICE file and/or the repository https://github.com/carbynestack/cli. | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
|
@@ -14,18 +14,19 @@ on: | |
branches: | ||
- 'master' | ||
jobs: | ||
test: | ||
runs-on: ubuntu-20.04 | ||
build: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
- name: Set up JDK 11 | ||
uses: actions/setup-java@v2 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '11' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
- name: Setting up Github Package Repository as Maven Repository | ||
uses: s4u/maven-settings-action@v2 | ||
uses: s4u/maven-settings-action@v2.8.0 | ||
with: | ||
githubServer: false | ||
servers: | | ||
|
@@ -36,6 +37,28 @@ jobs: | |
}] | ||
- name: Build with Maven | ||
run: mvn install -Dskip.tests --batch-mode --update-snapshots --no-transfer-progress | ||
test: | ||
runs-on: ubuntu-22.04 | ||
needs: build | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
- name: Set up JDK 11 | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '11' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
- name: Setting up Github Package Repository as Maven Repository | ||
uses: s4u/[email protected] | ||
with: | ||
githubServer: false | ||
servers: | | ||
[{ | ||
"id": "github", | ||
"username": "${{ github.actor }}", | ||
"password": "${{ secrets.GITHUB_TOKEN }}" | ||
}] | ||
- name: Run Tests | ||
run: mvn verify --activate-profiles coverage --batch-mode --no-transfer-progress | ||
- name: Collect Jacoco reports | ||
|
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 |
---|---|---|
@@ -0,0 +1,68 @@ | ||
# | ||
# Copyright (c) 2021-2023 - for information on the respective copyright owner | ||
# see the NOTICE file and/or the repository https://github.com/carbynestack/cli. | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
name: Publish and Release | ||
on: | ||
push: | ||
tags: | ||
- "cli-v[0-9]+.[0-9]+.[0-9]+" | ||
jobs: | ||
publish: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v2 | ||
- name: Retrieve license obligation resources | ||
id: license-obligations | ||
run: | | ||
cd 3RD-PARTY-LICENSES | ||
FILES=$(find . -maxdepth 1 -type d -not -path .) | ||
if [ -n "$FILES" ] | ||
then | ||
echo "${FILES}" | zip -r@ 3rd-party-copyrights | ||
fi | ||
find . -iname origin.src | \ | ||
awk '{ \ | ||
split($0,b,"/"); \ | ||
system("xargs < " $0 " curl --create-dirs -Lo ./sources/" b[2] ".zip " $2)}' && \ | ||
find -regex './sources$' | awk '{system("zip -jr ./3rd-party-sources.zip " $0)}' | ||
mkdir -p ../license-obligations | ||
ARCHIVES=$(find . -regex "^./3rd-party-.*.zip$") | ||
OBLIGATIONS_FOUND="false" | ||
if [ -n "$ARCHIVES" ] | ||
then | ||
mv $(echo "${ARCHIVES}") ../license-obligations/ | ||
OBLIGATIONS_FOUND="true" | ||
fi | ||
echo "OBLIGATIONS_FOUND=${OBLIGATIONS_FOUND}" >> $GITHUB_OUTPUT | ||
- name: Update Release with license obligations resources | ||
uses: ncipollo/release-action@v1 | ||
if: steps.license-obligations.outputs.OBLIGATIONS_FOUND == 'true' | ||
with: | ||
allowUpdates: true | ||
artifacts: license-obligations/* | ||
artifactErrorsFailBuild: true | ||
makeLatest: true | ||
omitBodyDuringUpdate: true | ||
omitNameDuringUpdate: true | ||
- name: Setup java | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '11' | ||
distribution: 'temurin' | ||
cache: 'maven' | ||
- name: Setting up Github Package Repository as Maven Repository | ||
uses: s4u/[email protected] | ||
with: | ||
githubServer: false | ||
servers: | | ||
[{ | ||
"id": "github", | ||
"username": "${{ secrets.GHPR_USERNAME }}", | ||
"password": "${{ secrets.GHPR_TOKEN }}" | ||
}] | ||
- name: Publish version to GitHub Packages | ||
run: mvn deploy -Dskip.tests --batch-mode --no-transfer-progress |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# | ||
# Copyright (c) 2023 - for information on the respective copyright owner | ||
# see the NOTICE file and/or the repository https://github.com/carbynestack/cli. | ||
# | ||
# SPDX-License-Identifier: Apache-2.0 | ||
# | ||
name: Release | ||
on: | ||
push: | ||
branches: | ||
- master | ||
jobs: | ||
release-please: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Release Please | ||
uses: google-github-actions/release-please-action@v3 | ||
with: | ||
command: manifest | ||
signoff: "cs-minion <[email protected]>" | ||
token: ${{ secrets.CS_MINION_PAT }} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
".": "0.3.0" | ||
} |
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
Oops, something went wrong.