Explorar o código

use %0A in github workflow because \n is truncated

narodnik %!s(int64=5) %!d(string=hai) anos
pai
achega
95c8abfc64
Modificáronse 1 ficheiros con 3 adicións e 1 borrados
  1. 3 1
      .github/workflows/matrix-commit-message.yml

+ 3 - 1
.github/workflows/matrix-commit-message.yml

@@ -13,7 +13,9 @@ jobs:
           ALL_MSGS=""
           for i in ${{ join(github.event.commits.*.id, ' ') }}; do
             MSG=$(git --no-pager show -s --format='%h <b>%an</b>: %s' $i)
-            ALL_MSGS="$ALL_MSGS$MSG"$'\n'
+            # From this link the newline character is: %0A
+            # https://github.community/t/set-output-truncates-multiline-strings/16852
+            ALL_MSGS="$ALL_MSGS$MSG%0A"
           done
           echo "::set-output name=COMMIT_MESSAGE::$ALL_MSGS"
         id: commit-message