From 6ab7d417412897fb991282f52b74a3aba693431a Mon Sep 17 00:00:00 2001 From: Paul van Tilburg Date: Sat, 27 Jul 2024 14:07:22 +0200 Subject: [PATCH] Fix release notes being escaped properly The release notes can contain special characters that will be expanded by bash if not escaped properly, such as the dollar sign (`$`) or the backtick (`\``). This PR replaces setting the `RELEASENOTES` environment variable using double quotes by a heredoc that does not perform any shell-related expansion. --- action.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 07e73d5..125dd93 100644 --- a/action.yml +++ b/action.yml @@ -81,7 +81,10 @@ runs: export RELEASE_DIR="${{ inputs.release-dir }}" - export RELEASENOTES="${{ inputs.release-notes }}" + export RELEASENOTES=$(cat << 'EOF' + ${{ inputs.release-notes }} + EOF + ) export SHA="${{ inputs.sha }}" if test -z "$SHA"; then