Skip to content

Commit

Permalink
check if is pr
Browse files Browse the repository at this point in the history
  • Loading branch information
miraclx committed Jul 4, 2022
1 parent 51c47f6 commit 6fc2fad
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,13 @@ jobs:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Check If Is PR
id: is_pr
run: |
if [[ "${{ github.event_name }}" != 'pull_request' ]]; then
echo "::set-output name=sha::type=sha,format=short,prefix="
fi
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@e5622373a38e60fb6d795a4421e56882f2d7a681
Expand All @@ -268,6 +275,7 @@ jobs:
tags: |
type=ref,event=pr
type=ref,event=branch
${{ steps.is_pr.outputs.sha }}
- name: Extract Tag
id: meta2
Expand Down

0 comments on commit 6fc2fad

Please sign in to comment.