Skip to content

Commit

Permalink
Added action check for different source and target branches (Palisado…
Browse files Browse the repository at this point in the history
…esFoundation#1715)

* Added action check for different source and target branches

* changed to bash deleting python

* added to code quality checks
  • Loading branch information
aarishshahmohsin authored Mar 17, 2024
1 parent cdaad16 commit b9df0aa
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ env:

jobs:
Code-Quality-Checks:
name: Performs linting, formatting, type-checking
name: Performs linting, formatting, type-checking, checking for different source and target branch
runs-on: ubuntu-latest
steps:
- name: Checkout the Repository
Expand Down Expand Up @@ -66,6 +66,13 @@ jobs:
chmod +x .github/workflows/compare_translations.py
python .github/workflows/compare_translations.py --directory public/locales
- name: Check if the source and target branches are different
if: ${{ github.event.pull_request.base.ref == github.event.pull_request.head.ref }}
run: |
echo "Source Branch ${{ github.event.pull_request.head.ref }}"
echo "Target Branch ${{ github.event.pull_request.base.ref }}"
echo "Error: Source and Target Branches are the same. Please ensure they are different."
exit 1
Check-Changed-Files:
name: File count, sensitive files and branch check
Expand Down

0 comments on commit b9df0aa

Please sign in to comment.