-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Labels
enhancementNew feature or requestNew feature or request
Description
By default, dynamic-uses returns a single JSON output named outputs containing all the target action's outputs. Individual outputs can then be accessed via something like fromJSON(steps.cool-action.outputs.outputs).theThingIWant. This provides the most flexibility.
But sometimes you just want a single output, and if you have to do this in multiple expressions this can get a bit tedious/verbose. It would be nice if you could optionally specify a particular output to target, then the outputs output would contain its actual value.
e.g. instead of this
- id: cool-action
uses: jenseng/dynamic-uses@v1
with:
uses: my/cool/action@${{ inputs.version }}
- env:
theThing: ${{ fromJSON(steps.cool-action.outputs.outputs).theThingIWant }}
run: echo "$theThing"you could do something like this:
- id: cool-action
uses: jenseng/dynamic-uses@v1
with:
uses: my/cool/action@${{ inputs.version }}
output: theThingIWant
- env:
theThing: ${{ steps.cool-action.outputs.outputs }}
run: echo "$theThing"Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request