core.setOutput should support null separated values
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 5.9k
- Forks
- 1.8k
- PR merge metrics
- No merged PRs in 30d
Description
Describe the enhancement
Currently setOutput escapes new lines, but it would be great if it also escaped the null character so that one can use it to separate array outputs.
Additional information
Right now I'm using a new line to separate the array entries, but that means that if the entries have whitespaces we need to use the following:
echo "${{ steps.changed-files.outputs.files }}" | tr '\n' '\0' | xargs -0 ls -lh
However is setOutput supported null separated bytes, we could just do:
echo "${{ steps.changed-files.outputs.files }}" | xargs -0 ls -lh
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the TypeScript implementation and tests for setOutput in the toolkit. Check how newline escaping is handled, then define completion as null characters being escaped safely so output can be consumed by xargs -0 without the issue's shell conversion step.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100