Files
Gitea_Action_Test/.gitea/workflows/005_passing_data_between_jobs.yaml
2025-10-17 13:11:26 -07:00

24 lines
658 B
YAML

name: Passing Data Between Jobs
on:
workflow_dispatch:
jobs:
data-sender:
runs-on: ubuntu-22.04
steps:
- name: Create data
id: sender # Set the output name for this step to Apple
run: |
echo "name=Apple" >> $GITHUB_OUTPUT
outputs:
name: ${{ steps.sender.outputs.name }}
data-receiver:
runs-on: ubuntu-22.04
needs: ["data-sender"]
steps: # In order to have data for receiver sender needs to first produce some data.
- name: Receive data
# Notice how we use needs object to access the sender job's outputs
run: |
echo ${{ needs.data-sender.outputs.name }}