Skip to content

Commit

Permalink
fix github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
dpgiakatos committed Nov 8, 2024
1 parent 77a22b8 commit 2fd11c5
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion .github/workflows/validate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: PR Validation
on:
pull_request:
types: [edited, opened, synchronize, reopened]
branches: ["main", "dev"]
branches: ["*"]

jobs:
validate-pr:
Expand All @@ -12,6 +12,15 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v2

- name: Determine if PR is from fork
id: check_fork
run: |
if [ "${{ github.event.pull_request.head.repo.full_name }}" != "${{ github.repository }}" ]; then
echo "is_fork=true" >> $GITHUB_ENV
else
echo "is_fork=false" >> $GITHUB_ENV
fi
- name: Clear all PR labels
run: |
pr_number=${{ github.event.pull_request.number }}
Expand All @@ -23,6 +32,7 @@ jobs:
done
- name: Validate PR
if: env.is_fork == 'false'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
Expand Down

0 comments on commit 2fd11c5

Please sign in to comment.