From 5a8d6253dbac894f04fdffb5532ec90c5305229b Mon Sep 17 00:00:00 2001 From: Dmitry Nefedov Date: Mon, 16 Oct 2023 23:05:24 +0300 Subject: [PATCH] Update SophiApp.yml --- .github/workflows/SophiApp.yml | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/.github/workflows/SophiApp.yml b/.github/workflows/SophiApp.yml index 53cbbde3..a4aef102 100644 --- a/.github/workflows/SophiApp.yml +++ b/.github/workflows/SophiApp.yml @@ -91,15 +91,14 @@ jobs: } $Penultimate = (Invoke-RestMethod @Parameters).tag_name | Select-Object -Index 1 - # No need to replace special characters with percent-encoding ones $Parameters = @{ - Uri = "https://api.github.com/repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/jobs" - UseBasicParsing = $true - Verbose = $true + Uri = "https://api.github.com/repos/${{ github.repository }}/actions/runs/${{ github.run_id }}/jobs" + UseBasicParsing = $true + Verbose = $true } $html_url = ((Invoke-RestMethod @Parameters).jobs | Where-Object -FilterScript {$_.run_id -eq "${{ github.run_id }}"}).html_url - - (Get-Content -Path ReleaseNotesTemplate.md -Encoding utf8 -Raw).Replace("NewVersion", "${{ github.ref_name }}").Replace("OldVersion", $Penultimate).Replace("CurrentDate", $(Get-Date -f "dd.MM.yyyy")).Replace("html_url", $html_url).Replace("SHA256_hash", "${{ env.zip_hash }}") | Set-Content -Path ReleaseNotesTemplate.md -Encoding UTF8 + # No need to replace special characters with percent-encoding ones + (Get-Content -Path ReleaseNotesTemplate.md -Encoding utf8 -Raw).replace("NewVersion", "${{ github.ref_name }}").replace("OldVersion", $Penultimate).replace("CurrentDate", $(Get-Date -f "dd.MM.yyyy")).replace("html_url", $html_url).replace("SHA256_hash", "${{ steps.zip_hash.outputs.zip_hash }}") | Set-Content -Path ReleaseNotesTemplate.md -Encoding UTF8 -Force # https://en.wikipedia.org/wiki/Percent-encoding Add-Content -Path $env:GITHUB_OUTPUT -Value "ReleaseBody=ReleaseNotesTemplate.md"