Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions .github/workflows/build-executable-task.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ on:
required: false
type: boolean
default: false
outputs:
# Output of the uploaded artifact id
artifact-id:
value: ${{ jobs.upload-build-artifacts.outputs.artifact-id }}

jobs:

Expand Down Expand Up @@ -76,13 +72,11 @@ jobs:

# Smoke builds only need the per-runtime compile to succeed (fast PR
# feedback) — the zipped, downloadable artifact is a release concern, so
# skip the aggregation entirely on smoke. The `artifact-id` output is then
# empty, which is fine because the GitHub release job never runs on smoke.
# skip the aggregation entirely on smoke. The GitHub release job never runs
# on smoke, so no `release-asset-*` artifact is needed then.
upload-build-artifacts:
name: Upload matrix build artifacts job
if: ${{ !inputs.smoke }}
outputs:
artifact-id: ${{ steps.artifact-upload-step.outputs.artifact-id }}
runs-on: ubuntu-latest
needs: [ build-executable-matrix ]

Expand All @@ -98,9 +92,14 @@ jobs:
- name: Zip build output step
run: 7z a -t7z ${{ runner.temp }}/PlexCleaner.7z ${{ runner.temp }}/publish/*

# GitHub-release asset, uploaded under the `release-asset-<branch>-*`
# convention that the `github-release` job in build-release-task.yml
# collects by pattern (it never names this job) — so a derived project
# swaps its release contents by replacing this leaf task, not the
# orchestrator. Branch-suffixed so the publisher's branch matrix can
# build both branches in one run without colliding on the artifact name.
- name: Upload build artifacts step
id: artifact-upload-step
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: executable-build-${{ inputs.branch }}
name: release-asset-${{ inputs.branch }}-executable
path: ${{ runner.temp }}/PlexCleaner.7z
17 changes: 15 additions & 2 deletions .github/workflows/build-release-task.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,23 @@ jobs:
with:
ref: ${{ needs.get-version.outputs.GitCommitId }}

- name: Download executable build artifacts step
# Collect every release asset by the `release-asset-<branch>-*` artifact
# convention rather than naming individual build jobs, so this download
# step never changes when a derived project subsets targets: dropping a
# target (delete its job + this job's `needs` entry) just leaves one
# fewer `release-asset-*` to match, and a downstream ships different
# files by adding/replacing a leaf `build-*-task.yml` that uploads under
# this pattern. `merge-multiple` flattens the matched artifacts into one
# `./Publish` dir. download-artifact tolerates a zero-match pattern, but
# the release step below pins `fail_on_unmatched_files: true` over
# `./Publish/*`, so at least one `release-asset-*` must be present — the
# executable target supplies it. A project that drops every file-producing
# target must also relax that release-step guard.
- name: Download release asset artifacts step
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
artifact-ids: ${{ needs.build-executable.outputs.artifact-id }}
pattern: release-asset-${{ inputs.branch }}-*
merge-multiple: true
path: ./Publish

# The weekly publisher re-runs even when a branch has no new commits, so
Expand Down