Skip to content

Commit c15255e

Browse files
committed
chore: enhance GitHub workflows with concurrency and timeout settings
1 parent b74a68b commit c15255e

2 files changed

Lines changed: 17 additions & 3 deletions

File tree

.github/workflows/build-pr.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,34 @@
11
name: Build PR
22
on: [pull_request]
3+
concurrency:
4+
group: build-pr-${{ github.event.pull_request.number || github.ref }}
5+
cancel-in-progress: true
36
jobs:
47
build_pr:
58
if: github.repository_owner == 'OneLiteFeatherNET'
69
name: Build Pull Request Branch
710
runs-on: ${{ matrix.os }}
11+
timeout-minutes: 30
12+
permissions:
13+
contents: read
814
env:
915
ONELITEFEATHER_MAVEN_USERNAME: ${{ secrets.ONELITEFEATHER_MAVEN_USERNAME }}
1016
ONELITEFEATHER_MAVEN_PASSWORD: ${{ secrets.ONELITEFEATHER_MAVEN_PASSWORD }}
1117
strategy:
18+
fail-fast: false
1219
matrix:
1320
os: [ubuntu-latest, windows-latest, macos-latest]
1421
steps:
1522
- name: Checkout Repository
1623
uses: actions/checkout@v6
24+
- name: Validate Gradle Wrapper
25+
uses: gradle/actions/wrapper-validation@v5
1726
- name: Setup Java
1827
uses: actions/setup-java@v5
1928
with:
2029
distribution: temurin
21-
java-version: 24
30+
java-version: 21
2231
- name: Setup Gradle
2332
uses: gradle/actions/setup-gradle@v5
2433
- name: Build on ${{ matrix.os }}
25-
run: ./gradlew clean build test
34+
run: ./gradlew clean build

.github/workflows/sematic-releases.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,18 @@ name: Release
77
- beta
88
- "*.x"
99

10+
concurrency:
11+
group: release-${{ github.ref }}
12+
cancel-in-progress: true
13+
1014
permissions:
1115
contents: read # for checkout
1216

1317
jobs:
1418
release:
1519
name: Release
1620
runs-on: ubuntu-latest
21+
timeout-minutes: 45
1722
permissions:
1823
contents: write # to be able to publish a GitHub release
1924
issues: write # to be able to comment on released issues
@@ -47,4 +52,4 @@ jobs:
4752
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
4853
ONELITEFEATHER_MAVEN_USERNAME: ${{ secrets.ONELITEFEATHER_MAVEN_USERNAME }}
4954
ONELITEFEATHER_MAVEN_PASSWORD: ${{ secrets.ONELITEFEATHER_MAVEN_PASSWORD }}
50-
run: npx semantic-release
55+
run: npx semantic-release

0 commit comments

Comments
 (0)