From 3400cb980ea229246b1baca6ac4c0d8faa3347d5 Mon Sep 17 00:00:00 2001 From: Dmitry Verkhoturov Date: Fri, 1 Nov 2024 16:15:35 +0100 Subject: [PATCH] Test commit to generate changes --- .github/workflows/ci-build-site.yml | 15 +++++++++------ hugo/.size-limit.js | 2 +- hugo/src/scss/_archives.scss | 2 +- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci-build-site.yml b/.github/workflows/ci-build-site.yml index 23d3d948b..c3df9fe1b 100644 --- a/.github/workflows/ci-build-site.yml +++ b/.github/workflows/ci-build-site.yml @@ -148,7 +148,10 @@ jobs: PASTEBIN_API_KEY: ${{ secrets.PASTEBIN_API_KEY }} id: create-pastebin run: | - diff_content=$(cat changes.diff) + # Use a URL-encoded paste name to handle special characters + paste_name=$(echo "radio-t.com Site Changes for PR #${{ github.event.pull_request.number }}, commit ${{ github.sha }}" | jq -sRr @uri) + + # Post the diff file directly from changes.diff # https://pastebin.com/doc_api paste_output=$(curl --silent "https://pastebin.com/api/api_post.php" \ -d "api_dev_key=$PASTEBIN_API_KEY" \ @@ -156,11 +159,11 @@ jobs: -d "api_paste_expire_date=1M" \ -d "api_paste_format=diff" \ -d "api_paste_private=0" \ - -d "api_paste_code=${diff_content}" \ - -d "api_paste_name=radio-t.com Site Changes for PR #${{ github.event.pull_request.number }}, commit ${{ github.sha }}") - - # Check if the output is a valid URL, otherwise print error - if [[ "$paste_url" == "https://"* ]]; then + -d "api_paste_name=${paste_name}" \ + --data-urlencode "api_paste_code@changes.diff" || echo "curl call to pastebin failed") + + # Check if the output is a valid URL, otherwise print an error + if [[ "$paste_output" == "https://"* ]]; then echo "PASTE_URL=$paste_output" >> $GITHUB_ENV else echo "Error: Failed to create Pastebin paste: $paste_output" >&2 diff --git a/hugo/.size-limit.js b/hugo/.size-limit.js index 75112f8fa..d533bd201 100644 --- a/hugo/.size-limit.js +++ b/hugo/.size-limit.js @@ -1,7 +1,7 @@ module.exports = [ { path: 'static/build/app.js', - limit: '16 KB', + limit: '17 KB', }, { path: 'static/build/manifest.js', diff --git a/hugo/src/scss/_archives.scss b/hugo/src/scss/_archives.scss index 404d5b5b3..e857b7ff0 100644 --- a/hugo/src/scss/_archives.scss +++ b/hugo/src/scss/_archives.scss @@ -94,7 +94,7 @@ content: ''; position: absolute; bottom: 0; - left: $grid-gutter-width / 2; + left: $grid-gutter-width * 0.3; right: $grid-gutter-width / 2; height: 1px; background-color: $border-color;