Skip to content

Commit

Permalink
use job outputs and needs
Browse files Browse the repository at this point in the history
  • Loading branch information
diehlbw committed Jun 6, 2024
1 parent 6224b27 commit 5639ad1
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,11 @@ permissions: "read-all"

jobs:
# Check for label in its own job to allow skipping multiple steps with 'success'
check-changelog-needed:
name: changelog needed
check-labels:
name: check labels
runs-on: ubuntu-latest
steps:
- name: Check Labels
id: check_labels
- id: check-labels
env:
OWNER: ${{ github.repository_owner }}
REPO_NAME: ${{ github.event.repository.name }}
Expand All @@ -24,11 +23,14 @@ jobs:
echo "needs entry"
echo "needs_entry=true" >> "$GITHUB_OUTPUT"
fi
outputs:
needs_entry: ${{ steps.check-labels.outputs.needs_entry }}

check-changelog-entry:
name: changelog entry
name: has fragment
runs-on: ubuntu-latest
if: ${{ steps.check_labels.outputs.needs_entry == 'true' }}
needs: check-labels
if: ${{ needs.check-labels.outputs.needs_entry == 'true' }}
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down

0 comments on commit 5639ad1

Please sign in to comment.