Job build sets a step output version via $GITHUB_OUTPUT. Job release needs that value. Which configuration correctly exposes and consumes it?
Select an answer to reveal the explanation.
Short Explanation and Infographic
Step outputs stay inside a job until you map them in jobs.<id>.outputs; dependent jobs then read needs.<id>.outputs. GITHUB_ENV and secrets: inherit do not ferry outputs across jobs.
Full explanation below image
Full Explanation
Cross-job data flow requires three pieces: (1) a step writes name=value to GITHUB_OUTPUT, (2) the producing job declares outputs: version: ${{ steps.meta.outputs.version }} (with the step id), and (3) a consumer job lists needs: build and reads ${{ needs.build.outputs.version }}. Environment variables written to GITHUB_ENV never leave the job. secrets: inherit only affects reusable workflow secret availability, not job outputs. steps context is local to the current job—release cannot see steps from build without the outputs/needs bridge. Prefer small non-secret outputs; large files should travel as artifacts. If build is skipped, needs.build.outputs may be empty—guard release with if: conditions as needed.