feat(workflow): add support for multiline commands in "run" key#201
Merged
safl merged 1 commit intorefenv:mainfrom Dec 18, 2025
Merged
feat(workflow): add support for multiline commands in "run" key#201safl merged 1 commit intorefenv:mainfrom
safl merged 1 commit intorefenv:mainfrom
Conversation
9d6dc41 to
9478b3e
Compare
Pull Request Test Coverage Report for Build 20308593984Details
💛 - Coveralls |
Before, it was not possible to create a workflow steps like:
- name: do_multiple_things
run: |
cd /some/long/path; \
echo "hello world" > hello.txt; \
cat hello.txt
- name: have_many_arguments
run: |
./run_something.sh \
--arg1 value1 \
--arg2 value2 \
--arg2 value3
This could end up forcing users to either have very long lines in the
workflow, if many arguments had to be given to a tool, *or* have a `cd`
prefix for every command in a list of commands if they all had to be
executed in a specific directory.
This commit adds multiline support, which follows the syntax of shell
scripts where a backslash (\) continues the command onto the next line.
Signed-off-by: Nadja Brix Koch <n.koch@samsung.com>
9478b3e to
f77cbaf
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Before, it was not possible to create a workflow steps like:
This could end up forcing users to either have very long lines in the workflow, if many arguments had to be given to a tool, or have a
cdprefix for every command in a list of commands if they all had to be executed in a specific directory.This commit adds multiline support, which follows the syntax of shell scripts where a backslash () continues the command onto the next line.
This will fix #199