Where I have a job step that sets an output, e.g. ...
# github-workflows-kt
c
Where I have a job step that sets an output, e.g.
Copy code
run(command = """echo "compat=${'$'}(jq -c . < .github/compatibility-test-matrix.json)" >> ${'$'}GITHUB_OUTPUT""")
How can I access that output for later use? Using
Copy code
readTestMatrix.outputs.compat
result in a “not initialized” error, as expected, as I’ve not set anything. There is nothing on CommandStep to grab an output afaik.
p
This functionality indeed seems to exist only for the action step, not the command step. Looks like simply a missing feature that should be there, feel free to open a feature request in GitHub. For a workaround, see what @Nikky wrote in the below thread
To see why your workflow doesn't work as expected, I'd need a full reproducer. E. g. I don't know what readTestMatrix is
I'll be able to properly review the existing and a possible new API once I'm back from vacation and I have access to the computer