Skip to content

Commit

Permalink
Added Base branch check to main (#2357)
Browse files Browse the repository at this point in the history
  • Loading branch information
palisadoes authored Jan 29, 2024
1 parent e07d4eb commit 4d25b76
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
pr-message: "Congratulations on making your first PR! :confetti_ball: If you haven't already, check out our [Contributing Guidelines](https://github.com/PalisadoesFoundation/talawa/blob/master/CONTRIBUTING.md) and [PR Reporting Guidelines](https://github.com/PalisadoesFoundation/talawa/blob/master/PR-guidelines.md) to ensure that you are following our guidelines for contributing and creating PR."

Linter:
name: Checking if code formatting is done correctly
runs-on: ubuntu-latest
Expand All @@ -22,7 +22,7 @@ jobs:
githubToken: ${{ secrets.GITHUB_TOKEN }}
- uses: subosito/flutter-action@v1
with:
channel: 'beta'
channel: "beta"
- run: flutter format --set-exit-if-changed .

Count-lines-of-code:
Expand Down Expand Up @@ -50,16 +50,24 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Sets up a Flutter environment
- name: Sets up a Flutter environment
uses: subosito/flutter-action@v1
with:
channel: 'beta'
channel: "beta"
- name: Generates LCOV file
run: flutter test --coverage
- name: Report code coverage
uses: VeryGoodOpenSource/[email protected]
with:
path: "./coverage/lcov.info"
min_coverage: 30


Branch-check:
name: "Base branch check"
runs-on: ubuntu-latest
steps:
- name: "Check if base branch is develop"
if: github.event.pull_request.base.ref != 'develop'
run: |
echo "PR is not against develop branch. Please refer PR_GUIDELINES.md"
exit 1

0 comments on commit 4d25b76

Please sign in to comment.