-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from bee-produced/7-pipeline
Pipeline + Publish Artifacts to Maven Central
- Loading branch information
Showing
10 changed files
with
615 additions
and
39 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 |
---|---|---|
@@ -0,0 +1,134 @@ | ||
name: Build, Test & Publish | ||
on: | ||
push: | ||
tags: | ||
- '*' | ||
branches: | ||
- '**' | ||
jobs: | ||
Build-Test: | ||
runs-on: ubuntu-latest | ||
if: "!startsWith(github.ref, 'refs/tags/')" | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Setup Java | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'adopt' | ||
cache: 'gradle' | ||
- name: Make gradlew executable | ||
run: | | ||
chmod +x ./bee.persistent/gradlew | ||
chmod +x ./bee.functional/gradlew | ||
chmod +x ./bee.buzz/gradlew | ||
chmod +x ./bee.generative/gradlew | ||
chmod +x ./bee.fetched/gradlew | ||
chmod +x ./bee.fetched.test/gradlew | ||
chmod +x ./example/application/gradlew | ||
- name: Build & Test bee.persistent | ||
working-directory: ./bee.persistent | ||
run: ./gradlew build | ||
- name: Build & Test bee.functional | ||
working-directory: ./bee.functional | ||
run: ./gradlew build | ||
- name: Build & Test bee.buzz | ||
working-directory: ./bee.buzz | ||
run: ./gradlew build | ||
- name: Build & Test bee.generative | ||
working-directory: ./bee.generative | ||
run: ./gradlew build | ||
- name: Build & Test bee.fetched | ||
run: | | ||
cd ./bee.fetched/ | ||
./gradlew build | ||
cd ../bee.fetched.test/ | ||
./gradlew build | ||
- name: Build & Test example application | ||
working-directory: ./example/application | ||
run: ./gradlew build | ||
|
||
Build-Test-Publish: | ||
runs-on: ubuntu-latest | ||
if: "startsWith(github.ref, 'refs/tags/')" | ||
env: | ||
JRELEASER_NEXUS2_USERNAME: ${{ secrets.JRELEASER_NEXUS2_USERNAME }} | ||
JRELEASER_NEXUS2_PASSWORD: ${{ secrets.JRELEASER_NEXUS2_PASSWORD }} | ||
JRELEASER_GPG_PASSPHRASE: ${{ secrets.JRELEASER_GPG_PASSPHRASE }} | ||
JRELEASER_GPG_SECRET_KEY: ${{ secrets.JRELEASER_GPG_SECRET_KEY }} | ||
JRELEASER_GPG_PUBLIC_KEY: ${{ secrets.JRELEASER_GPG_PUBLIC_KEY }} | ||
JRELEASER_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
- name: Remove -SNAPSHOT suffix from bee-built version | ||
run: sed -i '/bee-built/ s/-SNAPSHOT//g' ./gradle/libs.versions.toml | ||
- name: Setup Java | ||
uses: actions/setup-java@v3 | ||
with: | ||
java-version: '17' | ||
distribution: 'adopt' | ||
cache: 'gradle' | ||
- name: Make gradlew executable | ||
run: | | ||
chmod +x ./bee.persistent/gradlew | ||
chmod +x ./bee.functional/gradlew | ||
chmod +x ./bee.buzz/gradlew | ||
chmod +x ./bee.generative/gradlew | ||
chmod +x ./bee.fetched/gradlew | ||
chmod +x ./bee.fetched.test/gradlew | ||
chmod +x ./example/application/gradlew | ||
- name: Build & Test bee.persistent | ||
working-directory: ./bee.persistent | ||
run: ./gradlew build | ||
- name: Build & Test bee.functional | ||
working-directory: ./bee.functional | ||
run: ./gradlew build | ||
- name: Build & Test bee.buzz | ||
working-directory: ./bee.buzz | ||
run: ./gradlew build | ||
- name: Build & Test bee.generative | ||
working-directory: ./bee.generative | ||
run: ./gradlew build | ||
- name: Build & Test bee.fetched | ||
run: | | ||
cd ./bee.fetched/ | ||
./gradlew build | ||
cd ../bee.fetched.test/ | ||
./gradlew build | ||
- name: Build & Test example application | ||
working-directory: ./example/application | ||
run: ./gradlew build | ||
|
||
- name: Publish bee.persistent | ||
continue-on-error: true | ||
working-directory: ./bee.persistent | ||
run: | | ||
./gradlew publish | ||
./gradlew jreleaserDeploy | ||
- name: Publish bee.functional | ||
continue-on-error: true | ||
working-directory: ./bee.functional | ||
run: | | ||
./gradlew publish | ||
./gradlew jreleaserDeploy | ||
- name: Publish bee.buzz | ||
continue-on-error: true | ||
working-directory: ./bee.buzz | ||
run: | | ||
./gradlew publish | ||
./gradlew jreleaserDeploy | ||
- name: Publish bee.generative | ||
continue-on-error: true | ||
working-directory: ./bee.generative | ||
run: | | ||
./gradlew publish | ||
./gradlew jreleaserDeploy | ||
- name: Publish bee.fetched | ||
continue-on-error: true | ||
working-directory: ./bee.fetched | ||
run: | | ||
./gradlew publish | ||
./gradlew jreleaserDeploy | ||
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
Oops, something went wrong.