diff --git a/dist/index.js b/dist/index.js index 366b69dd..a0f111b2 100644 --- a/dist/index.js +++ b/dist/index.js @@ -133,7 +133,10 @@ function run() { const overwrite = core.getInput('overwrite') == 'true' ? true : false; const prerelease = core.getInput('prerelease') == 'true' ? true : false; const release_name = core.getInput('release_name'); - const body = core.getInput('body'); + const body = core.getInput('body') + .replace(/%25/g, '%') + .replace(/%0A/ig, '\n') + .replace(/%0D/ig, '\r'); const octokit = github.getOctokit(token); const release = yield get_release_by_tag(tag, prerelease, release_name, body, octokit); if (file_glob) { diff --git a/src/main.ts b/src/main.ts index 54e69f5e..328c8b71 100644 --- a/src/main.ts +++ b/src/main.ts @@ -142,10 +142,11 @@ async function run(): Promise { const overwrite = core.getInput('overwrite') == 'true' ? true : false const prerelease = core.getInput('prerelease') == 'true' ? true : false const release_name = core.getInput('release_name') - const body = core.getInput('body') - .replace(/%25/g, '%') - .replace(/%0A/ig, '\n') - .replace(/%0D/ig, '\r') + const body = core + .getInput('body') + .replace(/%25/g, '%') + .replace(/%0A/gi, '\n') + .replace(/%0D/gi, '\r') const octokit = github.getOctokit(token) const release = await get_release_by_tag(