From d7ca5f2297b184acc5318a2aab4b9c6bb309ed0b Mon Sep 17 00:00:00 2001 From: Zach Borboa Date: Tue, 17 Oct 2023 12:06:37 -0700 Subject: [PATCH] Fix pre-commit workflow error when writing multiline string Error message: Error: Unable to process file command 'output' successfully. Error: Invalid format 'index cd0e971..e9a93b2 100644' --- .github/workflows/pre-commit-auto-update.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pre-commit-auto-update.yml b/.github/workflows/pre-commit-auto-update.yml index 561fba5..b17a568 100644 --- a/.github/workflows/pre-commit-auto-update.yml +++ b/.github/workflows/pre-commit-auto-update.yml @@ -26,7 +26,10 @@ jobs: run: | git diff --color changes="$(git diff)" - echo "changes=${changes}" >> $GITHUB_OUTPUT + delimiter="$(openssl rand -hex 8)" + echo "changes<<${delimiter}" >> "${GITHUB_OUTPUT}" + echo "${changes}" >> "${GITHUB_OUTPUT}" + echo "${delimiter}" >> "${GITHUB_OUTPUT}" - name: Create pull request uses: peter-evans/create-pull-request@v5