Send valid JSON to autosync workflows for multi-line commit messages (#1981)

Allow multi-line commit message to be used in autosync workflows using the toJSON context function. The toJSON function is required to pretty-print JSON objects to the log.
This commit is contained in:
Octavian FlowiseAI 2024-03-18 09:09:21 +01:00 committed by GitHub
parent bb7373ee62
commit 50a2e911f2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 2 deletions

View File

@ -28,6 +28,6 @@ jobs:
"ref": "${{ github.ref }}",
"prNumber": "${{ github.event.pull_request.number }}",
"prTitle": "${{ github.event.pull_request.title }}",
"prDescription": "${{ github.event.pull_request.description }}",
"prDescription": "${{ toJSON(github.event.pull_request.description) }}",
"sha": "${{ github.sha }}"
}

View File

@ -32,5 +32,5 @@ jobs:
{
"ref": "${{ github.ref }}",
"sha": "${{ github.sha }}",
"commitMessage": "${{ github.event.commits[0].message }}"
"commitMessage": "${{ toJSON(github.event.commits[0].message) }}"
}