Add a step to generate a MANIFEST.MF file recording merge sources #60
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Check PRs | |
on: | |
pull_request: | |
types: | |
- labeled | |
- unlabeled | |
- opened | |
- reopened | |
- ready_for_review | |
- synchronize | |
jobs: | |
get_versions: | |
name: Get versions | |
runs-on: ubuntu-latest | |
outputs: | |
versions: ${{ steps.versions.outputs.versions }} | |
steps: | |
- name: Get versions from labels | |
id: versions | |
env: | |
LABELS: ${{ toJson(github.event.pull_request.labels.*.description) }} | |
run: echo "versions=$(echo $LABELS | jq -c '[.[] | select(. != null and (startswith("snapshot/") or startswith("pre/") or startswith("release/")))]')" >> "$GITHUB_OUTPUT" | |
check: | |
needs: get_versions | |
if: ${{ needs.get_versions.outputs.versions != '[]' }} | |
strategy: | |
matrix: | |
version: ${{ fromJson(needs.get_versions.outputs.versions) }} | |
uses: './.github/workflows/check.yml' | |
with: | |
version: ${{ matrix.version }} | |
push_changed: false | |
publish: false | |
# Publishing of PRs will only work correctly if we're only building a single one | |
# NOTE: There is no way to get the length of an array in Github Actions Expressions | |
# So the heuristic is: If it contains a comma, it's a list with more than one element. | |
publish_prs: ${{ !contains(needs.get_versions.outputs.versions, ',') }} |