Skip to content

Commit

Permalink
fix: migrate release-please to yoshi release type and codecov to flags
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastian Becker <[email protected]>
  • Loading branch information
sbckr committed Jul 27, 2023
1 parent 1e6d137 commit ae3eb26
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 9 deletions.
18 changes: 11 additions & 7 deletions .github/workflows/java.build-and-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,17 @@ jobs:
# Expose matched filters as job 'packages' output variable
modules: ${{ steps.filter.outputs.changes }}
steps:
- uses: dorny/paths-filter@v2
- name: Checkout repository
uses: actions/checkout@v3
- name: Check which modules are affected
uses: dorny/paths-filter@v2
id: filter
with:
filters: |
amphora-parent: '(amphora-parent|.github)/**'
amphora-common: '(amphora-common|.github)/**'
amphora-java-client: '(amphora-java-client|.github)/**'
amphora-service: '(amphora-service|.github)/**'
parent: '(amphora-parent|.github)/**'
common: '(amphora-common|.github)/**'
java-client: '(amphora-java-client|.github)/**'
service: '(amphora-service|.github)/**'
test:
needs: changes
strategy:
Expand All @@ -56,9 +59,9 @@ jobs:
"password": "${{ secrets.GITHUB_TOKEN }}"
}]
- name: Build with Maven
run: ./mvnw install -pl ${{ matrix.module }} -Dskip.tests --batch-mode --update-snapshots --no-transfer-progress
run: ./mvnw install -pl ${GITHUB_REPOSITORY#*/}-${{ matrix.module }} -Dskip.tests --batch-mode --update-snapshots --no-transfer-progress
- name: Run Tests
run: ./mvnw verify -pl ${{ matrix.module }} --activate-profiles coverage --batch-mode --no-transfer-progress
run: ./mvnw verify -pl ${GITHUB_REPOSITORY#*/}-${{ matrix.module }} --activate-profiles coverage --batch-mode --no-transfer-progress
- name: Collect Jacoco reports
run: echo ::set-output name=reports::$(find . -regex '.*/target/site/jacoco/jacoco.xml' | tr '\n' ',' | sed 's/.$//')
id: jacoco
Expand All @@ -68,6 +71,7 @@ jobs:
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{ steps.jacoco.outputs.reports }}
name: ${{ matrix.module }}
flags: ${{ matrix.module }}
test-status:
runs-on: ubuntu-22.04
needs: test
Expand Down
2 changes: 1 addition & 1 deletion .release-please-manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
".": "0.1.0",
"amphora-parent": "0.1.0",
"amphora-common": "0.1.0",
"amphora-java-client": "0.1.0",
"amphora-service": "0.1.0",
Expand Down
16 changes: 16 additions & 0 deletions codecov.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
flag_management:
default_rules:
carryforward: true
individual_flags:
- name: parent
paths:
- amphora-parent/
- name: common
paths:
- amphora-common/
- name: java-client
paths:
- amphora-java-client/
- name: service
paths:
- amphora-service/
2 changes: 1 addition & 1 deletion release-please-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"pull-request-header": ":package: Staging a new release",
"skip-snapshot": true,
"packages": {
".": {
"amphora-parent": {
"package-name": "parent",
"release-type": "maven"
},
Expand Down

0 comments on commit ae3eb26

Please sign in to comment.