From 537373c95d04e2ce4e01788f9df07d00c480614b Mon Sep 17 00:00:00 2001 From: Dilan Sachintha Nayanajith Date: Tue, 3 Oct 2023 21:09:56 +0530 Subject: [PATCH] Update pull-request.yml --- .github/workflows/pull-request.yml | 41 ++++++------------------------ 1 file changed, 8 insertions(+), 33 deletions(-) diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index d6e239e..b79d9d1 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -1,38 +1,13 @@ name: PR build +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.run_id }} + cancel-in-progress: true + on: pull_request jobs: - ubuntu-build: - name: Build on Ubuntu - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: Set up JDK 17 - uses: actions/setup-java@v2 - with: - distribution: 'temurin' - java-version: 17.0.7 - - name: Build with Gradle - env: - packageUser: ${{ github.actor }} - packagePAT: ${{ secrets.GITHUB_TOKEN }} - run: ./gradlew build - - name: Generate CodeCov Report - if: github.event_name == 'pull_request' - uses: codecov/codecov-action@v2 - - windows-build: - name: Build on Windows - runs-on: windows-latest - steps: - - uses: actions/checkout@v1 - - name: Set up JDK 17 - uses: actions/setup-java@v1 - with: - java-version: 17.0.7 - - name: Build with Gradle - env: - packageUser: ${{ github.actor }} - packagePAT: ${{ secrets.GITHUB_TOKEN }} - run: ./gradlew.bat build + call_workflow: + name: Run PR Build Workflow + if: ${{ github.repository_owner == 'ballerina-platform' }} + uses: ballerina-platform/ballerina-standard-library/.github/workflows/pull-request-build-template.yml@main