From ee4e35e4486d0aff4add6ab21b11fc21a120cf2d Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 3 Mar 2025 16:40:58 +0100 Subject: [PATCH 01/45] bump default version to latest 0.18.1 --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 69aae2c..a27cafc 100644 --- a/action.yml +++ b/action.yml @@ -28,7 +28,7 @@ inputs: required: false lycheeVersion: description: "Use custom version of lychee link checker" - default: v0.18.0 + default: v0.18.1 required: false output: description: "Summary output file path" From 158365f327ae82f4a2bbc904daa7fdf5eb0ce3d6 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 3 Mar 2025 16:50:40 +0100 Subject: [PATCH 02/45] add checkbox option --- action.yml | 5 +++++ entrypoint.sh | 11 +++++++++++ 2 files changed, 16 insertions(+) diff --git a/action.yml b/action.yml index a27cafc..69b247e 100644 --- a/action.yml +++ b/action.yml @@ -34,6 +34,10 @@ inputs: description: "Summary output file path" default: "lychee/out.md" required: false + checkbox: + description: "Add Markdown Styled Checkboxes to the output" + default: false + required: false token: description: "Your GitHub Access Token, defaults to: {{ github.token }}" default: ${{ github.token }} @@ -117,6 +121,7 @@ runs: INPUT_FAILIFEMPTY: ${{ inputs.FAILIFEMPTY }} INPUT_FORMAT: ${{ inputs.FORMAT }} INPUT_JOBSUMMARY: ${{ inputs.JOBSUMMARY }} + INPUT_CHECKBOX: ${{ inputs.CHECKBOX }} INPUT_OUTPUT: ${{ inputs.OUTPUT }} shell: bash branding: diff --git a/entrypoint.sh b/entrypoint.sh index 5711db3..a48344f 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -34,6 +34,17 @@ if [[ "$ARGS" =~ "--output " ]] && [ -n "${INPUT_OUTPUT:-}" ]; then exit 1 fi +# If `--mode task` occurs in args and `INPUT_CHECKBOX` is set, exit with an error +if [[ "$ARGS" =~ "--mode task" ]] && [ -n "${INPUT_CHECKBOX:-}" ]; then + echo "Error: '--mode task' is set in args as well as in the action configuration. Please remove one of them." + exit 1 +fi + +# Add `--mode task` to args if `INPUT_CHECKBOX` is true +if [[ "${INPUT_CHECKBOX}" = true ]]; then + ARGS="${ARGS} --mode task" +fi + # Execute lychee eval lychee ${FORMAT} --output ${LYCHEE_TMP} ${ARGS} LYCHEE_EXIT_CODE=$? From 43a64ff34473326464942cbd824b900c0b466f83 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 4 Mar 2025 17:21:57 +0100 Subject: [PATCH 03/45] Update action.yml - checkbox is by default true now --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 69b247e..90a7bb4 100644 --- a/action.yml +++ b/action.yml @@ -36,7 +36,7 @@ inputs: required: false checkbox: description: "Add Markdown Styled Checkboxes to the output" - default: false + default: true required: false token: description: "Your GitHub Access Token, defaults to: {{ github.token }}" From 57db59e845908f475f54a7e8cc5337f506bfd2b7 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 4 Mar 2025 17:23:38 +0100 Subject: [PATCH 04/45] Update entrypoint.sh - fixed error message - checks for `--mode` and not only for `--mode task` now --- entrypoint.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index a48344f..826b53b 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -34,10 +34,11 @@ if [[ "$ARGS" =~ "--output " ]] && [ -n "${INPUT_OUTPUT:-}" ]; then exit 1 fi -# If `--mode task` occurs in args and `INPUT_CHECKBOX` is set, exit with an error -if [[ "$ARGS" =~ "--mode task" ]] && [ -n "${INPUT_CHECKBOX:-}" ]; then - echo "Error: '--mode task' is set in args as well as in the action configuration. Please remove one of them." - exit 1 +# If `--mode` occurs in args and `INPUT_CHECKBOX` is set, exit with an error +# Use `--mode` instead of `--mode task` to ensure that the checkbox is not getting overwritten +if [[ "$ARGS" =~ "--mode" ]] && [ -n "${INPUT_CHECKBOX:-}" ]; then + echo "Error: '--mode' is set in args but 'checkbox' is set in the action configuration. Please remove one of them to avoid conflicts." + exit 1 fi # Add `--mode task` to args if `INPUT_CHECKBOX` is true From b58fc0cffcdadc31bc8de90ba3eaf0390ad0a3f5 Mon Sep 17 00:00:00 2001 From: Ben Date: Wed, 5 Mar 2025 13:15:21 +0100 Subject: [PATCH 05/45] fixed checkbox args --- entrypoint.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index 826b53b..b9492c0 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -28,6 +28,7 @@ FORMAT="" # If `format` occurs in args, ignore the value from `INPUT_FORMAT` [[ "$ARGS" =~ "--format " ]] || FORMAT="--format ${INPUT_FORMAT}" + # If `output` occurs in args and `INPUT_OUTPUT` is set, exit with an error if [[ "$ARGS" =~ "--output " ]] && [ -n "${INPUT_OUTPUT:-}" ]; then echo "Error: 'output' is set in args as well as in the action configuration. Please remove one of them." @@ -41,13 +42,13 @@ if [[ "$ARGS" =~ "--mode" ]] && [ -n "${INPUT_CHECKBOX:-}" ]; then exit 1 fi -# Add `--mode task` to args if `INPUT_CHECKBOX` is true -if [[ "${INPUT_CHECKBOX}" = true ]]; then - ARGS="${ARGS} --mode task" +CHECKBOX="" +if [ "${INPUT_CHECKBOX}" = true ]; then + CHECKBOX="--mode task" fi # Execute lychee -eval lychee ${FORMAT} --output ${LYCHEE_TMP} ${ARGS} +eval lychee ${CHECKBOX} ${FORMAT} --output ${LYCHEE_TMP} ${ARGS} LYCHEE_EXIT_CODE=$? # If no links were found and `failIfEmpty` is set to `true` (and it is by default), From 41456f69139f599294bd45a2e6cf63a19fe8fd81 Mon Sep 17 00:00:00 2001 From: Ben Date: Wed, 5 Mar 2025 13:21:40 +0100 Subject: [PATCH 06/45] Update test.yml fixed test --- .github/workflows/test.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5a11871..53c0d74 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -25,6 +25,7 @@ jobs: - name: test explicit lychee version uses: ./ with: + checkbox: false # not supported in v0.15.1 lycheeVersion: v0.15.1 - name: test nightly lychee version From 18fd888f411014ed1589225fcf79c2eceee0a70f Mon Sep 17 00:00:00 2001 From: Ben Date: Wed, 5 Mar 2025 13:29:26 +0100 Subject: [PATCH 07/45] added version check for checkbox --- .github/workflows/test.yml | 1 + entrypoint.sh | 7 ++++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 53c0d74..444d08d 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -287,6 +287,7 @@ jobs: - name: test explicit lychee version uses: ./ with: + checkbox: false # not supported in v0.15.1 lycheeVersion: v0.15.1 - name: test nightly lychee version diff --git a/entrypoint.sh b/entrypoint.sh index b9492c0..57df7b5 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -44,7 +44,12 @@ fi CHECKBOX="" if [ "${INPUT_CHECKBOX}" = true ]; then - CHECKBOX="--mode task" + # Check if the version is higher than 0.18.1 + if [ "$(lychee --version | head -n1 | cut -d" " -f4)" -lt 0.18.1 ]; then + echo "WARNING: 'checkbox' is not supported in lychee versions lower than 0.18.1. Continuing without 'checkbox'." + else + CHECKBOX="--mode task" + fi fi # Execute lychee From 9bdcfd4a38c7fc99e44bfab15ef33fc0d397eb07 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:02:51 +0200 Subject: [PATCH 08/45] Create lychee-version.yml --- .github/workflows/lychee-version.yml | 65 ++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 .github/workflows/lychee-version.yml diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml new file mode 100644 index 0000000..e4869c3 --- /dev/null +++ b/.github/workflows/lychee-version.yml @@ -0,0 +1,65 @@ +name: "Check Lychee Version and Create PR" + +on: + schedule: + - cron: "0 0 * * 0" # every Sunday + workflow_dispatch: + +jobs: + check-lychee-version: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Get current lychee release version + id: get-lychee-release + run: | + release=$(curl -s https://api.github.com/repos/lycheeverse/lychee/releases/latest | jq -r .tag_name) + echo "release_version=$release" >> $GITHUB_ENV + + - name: Extract lycheeVersion from action.yml + id: get-action-lychee-version + run: | + lychee_version=$(grep -Po '(?<=lycheeVersion:\s*default:\s*)v[0-9.]*' action.yml) + echo "action_lychee_version=$lychee_version" >> $GITHUB_ENV + + - name: Compare versions + id: compare-versions + run: | + if [ "$action_lychee_version" != "$release_version" ]; then + echo "Mismatch detected: action.yml lycheeVersion ($action_lychee_version) does not match latest release ($release_version)" + echo "## Update lycheeVersion to $release_version" > update-lychee-version.md + exit 0 + else + echo "Versions match: $action_lychee_version" + fi + + create-pr: + needs: check-lychee-version + runs-on: ubuntu-latest + if: steps.compare-versions.outputs.mismatch == 'true' + + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Create branch for update + run: | + git config --global user.name 'github-actions' + git config --global user.email 'github-actions@github.com' + git checkout -b update-lychee-version + sed -i "s/$action_lychee_version/$release_version/" action.yml + git commit -am "Update lycheeVersion to $release_version" + git push origin update-lychee-version + + - name: Create Pull Request + uses: peter-evans/create-pull-request@v4 + with: + token: ${{ secrets.GITHUB_TOKEN }} + branch: update-lychee-version + title: "Update lycheeVersion to $release_version" + body: "This PR updates the lycheeVersion to the latest release version $release_version." + labels: "automated pr" + assignees: arteiii From 577cd3a2496aa91334da2b3d7d50527501555afe Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:04:49 +0200 Subject: [PATCH 09/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index e4869c3..6664566 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -9,6 +9,7 @@ jobs: check-lychee-version: runs-on: ubuntu-latest + name: Check lychee version steps: - name: Checkout repository uses: actions/checkout@v3 @@ -41,6 +42,7 @@ jobs: runs-on: ubuntu-latest if: steps.compare-versions.outputs.mismatch == 'true' + name: Create PR to update lychee version steps: - name: Checkout repository uses: actions/checkout@v3 From 6f61d908592440ba18e79d7ce0424262ddb2de0a Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:07:16 +0200 Subject: [PATCH 10/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 6664566..f04c8fb 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -31,16 +31,15 @@ jobs: run: | if [ "$action_lychee_version" != "$release_version" ]; then echo "Mismatch detected: action.yml lycheeVersion ($action_lychee_version) does not match latest release ($release_version)" - echo "## Update lycheeVersion to $release_version" > update-lychee-version.md - exit 0 + echo "mismatch=true" >> $GITHUB_ENV else - echo "Versions match: $action_lychee_version" + echo "mismatch=false" >> $GITHUB_ENV fi create-pr: needs: check-lychee-version runs-on: ubuntu-latest - if: steps.compare-versions.outputs.mismatch == 'true' + if: env.mismatch == 'true' name: Create PR to update lychee version steps: From 605ae2dd67958e7952db22bf42d0337fff5b28bd Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:12:57 +0200 Subject: [PATCH 11/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index f04c8fb..1274e45 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -9,6 +9,9 @@ jobs: check-lychee-version: runs-on: ubuntu-latest + outputs: + mismatch: ${{ steps.compare-versions.outputs.mismatch }} + name: Check lychee version steps: - name: Checkout repository @@ -30,16 +33,15 @@ jobs: id: compare-versions run: | if [ "$action_lychee_version" != "$release_version" ]; then - echo "Mismatch detected: action.yml lycheeVersion ($action_lychee_version) does not match latest release ($release_version)" echo "mismatch=true" >> $GITHUB_ENV + echo "::set-output name=mismatch::true" else echo "mismatch=false" >> $GITHUB_ENV - fi create-pr: needs: check-lychee-version runs-on: ubuntu-latest - if: env.mismatch == 'true' + if: needs.check-lychee-version.outputs.mismatch == 'true' name: Create PR to update lychee version steps: From 7d059015b403a565283721db1274048c88061cfa Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:14:08 +0200 Subject: [PATCH 12/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 1274e45..67d4a65 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -26,7 +26,7 @@ jobs: - name: Extract lycheeVersion from action.yml id: get-action-lychee-version run: | - lychee_version=$(grep -Po '(?<=lycheeVersion:\s*default:\s*)v[0-9.]*' action.yml) + lychee_version=$(sed -n 's/.*lycheeVersion:\s*default:\s*\(v[0-9.]*\).*/\1/p' action.yml) echo "action_lychee_version=$lychee_version" >> $GITHUB_ENV - name: Compare versions From b326924abe73bcb1b775b5a062693813aeca9212 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:15:47 +0200 Subject: [PATCH 13/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 67d4a65..b51ba94 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -37,6 +37,7 @@ jobs: echo "::set-output name=mismatch::true" else echo "mismatch=false" >> $GITHUB_ENV + fi create-pr: needs: check-lychee-version From 5537d95a7098809b1540239269d2ccc7c7006c11 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:17:49 +0200 Subject: [PATCH 14/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index b51ba94..9444ce1 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -54,7 +54,7 @@ jobs: git config --global user.name 'github-actions' git config --global user.email 'github-actions@github.com' git checkout -b update-lychee-version - sed -i "s/$action_lychee_version/$release_version/" action.yml + sed -i "s/${{ github.env.action_lychee_version }}/${{ github.env.release_version }}/" action.yml git commit -am "Update lycheeVersion to $release_version" git push origin update-lychee-version From fb8e36d8568fda49b1e8d758409dbd74fcb74f56 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:23:53 +0200 Subject: [PATCH 15/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 9444ce1..98ed85a 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -11,6 +11,8 @@ jobs: outputs: mismatch: ${{ steps.compare-versions.outputs.mismatch }} + action_lychee_version: ${{ steps.get-action-lychee-version.outputs.action_lychee_version }} + release_version: ${{ steps.get-lychee-release.outputs.release_version }} name: Check lychee version steps: @@ -21,22 +23,21 @@ jobs: id: get-lychee-release run: | release=$(curl -s https://api.github.com/repos/lycheeverse/lychee/releases/latest | jq -r .tag_name) - echo "release_version=$release" >> $GITHUB_ENV + echo "release_version=$release" >> $GITHUB_OUTPUT - name: Extract lycheeVersion from action.yml id: get-action-lychee-version run: | lychee_version=$(sed -n 's/.*lycheeVersion:\s*default:\s*\(v[0-9.]*\).*/\1/p' action.yml) - echo "action_lychee_version=$lychee_version" >> $GITHUB_ENV + echo "action_lychee_version=$lychee_version" >> $GITHUB_OUTPUT - name: Compare versions id: compare-versions run: | if [ "$action_lychee_version" != "$release_version" ]; then - echo "mismatch=true" >> $GITHUB_ENV - echo "::set-output name=mismatch::true" + echo "mismatch=true" >> $GITHUB_OUTPUT else - echo "mismatch=false" >> $GITHUB_ENV + echo "mismatch=false" >> $GITHUB_OUTPUT fi create-pr: @@ -45,6 +46,9 @@ jobs: if: needs.check-lychee-version.outputs.mismatch == 'true' name: Create PR to update lychee version + env: + action_lychee_version: ${{ needs.check-lychee-version.outputs.action_lychee_version }} + release_version: ${{ needs.check-lychee-version.outputs.release_version }} steps: - name: Checkout repository uses: actions/checkout@v3 @@ -54,7 +58,7 @@ jobs: git config --global user.name 'github-actions' git config --global user.email 'github-actions@github.com' git checkout -b update-lychee-version - sed -i "s/${{ github.env.action_lychee_version }}/${{ github.env.release_version }}/" action.yml + sed -i "s/$action_lychee_version/$release_version/" action.yml git commit -am "Update lycheeVersion to $release_version" git push origin update-lychee-version From 0da2584e227ed9a4ee8189c583d50de09db6ae19 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:24:46 +0200 Subject: [PATCH 16/45] test --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index b706f73..3591acb 100644 --- a/action.yml +++ b/action.yml @@ -28,7 +28,7 @@ inputs: required: false lycheeVersion: description: "Use custom version of lychee link checker" - default: v0.18.1 + default: v0.18.0 required: false output: description: "Summary output file path" From 12c117df3944d4154be3d4055324b775ec5c4e57 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:27:11 +0200 Subject: [PATCH 17/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 98ed85a..8d8e7c3 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -22,21 +22,30 @@ jobs: - name: Get current lychee release version id: get-lychee-release run: | + echo "Fetching the latest lychee release version..." release=$(curl -s https://api.github.com/repos/lycheeverse/lychee/releases/latest | jq -r .tag_name) + echo "Latest release version fetched: $release" echo "release_version=$release" >> $GITHUB_OUTPUT - name: Extract lycheeVersion from action.yml id: get-action-lychee-version run: | + echo "Extracting lycheeVersion from action.yml..." lychee_version=$(sed -n 's/.*lycheeVersion:\s*default:\s*\(v[0-9.]*\).*/\1/p' action.yml) + echo "Extracted lycheeVersion: $lychee_version" echo "action_lychee_version=$lychee_version" >> $GITHUB_OUTPUT - name: Compare versions id: compare-versions run: | + echo "Comparing versions..." + echo "Action lychee version: $action_lychee_version" + echo "Latest release version: $release_version" if [ "$action_lychee_version" != "$release_version" ]; then + echo "Versions do not match. Setting mismatch to true." echo "mismatch=true" >> $GITHUB_OUTPUT else + echo "Versions match. Setting mismatch to false." echo "mismatch=false" >> $GITHUB_OUTPUT fi @@ -55,11 +64,14 @@ jobs: - name: Create branch for update run: | + echo "Creating a new branch for the update..." git config --global user.name 'github-actions' git config --global user.email 'github-actions@github.com' git checkout -b update-lychee-version + echo "Updating action.yml with the new lychee version..." sed -i "s/$action_lychee_version/$release_version/" action.yml git commit -am "Update lycheeVersion to $release_version" + echo "Pushing the branch to the repository..." git push origin update-lychee-version - name: Create Pull Request From 2e801673ca2cc8b4f87cc9420db377b2b0057f2e Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:30:15 +0200 Subject: [PATCH 18/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 8d8e7c3..6d4d987 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -24,6 +24,7 @@ jobs: run: | echo "Fetching the latest lychee release version..." release=$(curl -s https://api.github.com/repos/lycheeverse/lychee/releases/latest | jq -r .tag_name) + release=${release#lychee-} # Strip the 'lychee-' prefix echo "Latest release version fetched: $release" echo "release_version=$release" >> $GITHUB_OUTPUT @@ -31,7 +32,11 @@ jobs: id: get-action-lychee-version run: | echo "Extracting lycheeVersion from action.yml..." - lychee_version=$(sed -n 's/.*lycheeVersion:\s*default:\s*\(v[0-9.]*\).*/\1/p' action.yml) + lychee_version=$(grep -Po '(?<=lycheeVersion:\s*default:\s*)v[0-9.]+' action.yml) + if [ -z "$lychee_version" ]; then + echo "Error: Failed to extract lycheeVersion from action.yml" + exit 1 + fi echo "Extracted lycheeVersion: $lychee_version" echo "action_lychee_version=$lychee_version" >> $GITHUB_OUTPUT From a8244529712c63f9063dbb90c918b7475a2ee877 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:35:48 +0200 Subject: [PATCH 19/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 6d4d987..e0ebaa9 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -32,13 +32,13 @@ jobs: id: get-action-lychee-version run: | echo "Extracting lycheeVersion from action.yml..." - lychee_version=$(grep -Po '(?<=lycheeVersion:\s*default:\s*)v[0-9.]+' action.yml) + lychee_version=$(grep -E '^ lycheeVersion:\s*default:\s*v[0-9]+\.[0-9]+\.[0-9]+' action.yml | sed -E 's/.*lycheeVersion:\s*default:\s*(v[0-9]+\.[0-9]+\.[0-9]+).*/\1/') if [ -z "$lychee_version" ]; then echo "Error: Failed to extract lycheeVersion from action.yml" exit 1 fi echo "Extracted lycheeVersion: $lychee_version" - echo "action_lychee_version=$lychee_version" >> $GITHUB_OUTPUT + echo "action_lychee_version=$lychee_version" >> "$GITHUB_OUTPUT" - name: Compare versions id: compare-versions From e574b6832479ea505ede232853aaf662e1122241 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:40:01 +0200 Subject: [PATCH 20/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index e0ebaa9..fe939c6 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -32,13 +32,13 @@ jobs: id: get-action-lychee-version run: | echo "Extracting lycheeVersion from action.yml..." - lychee_version=$(grep -E '^ lycheeVersion:\s*default:\s*v[0-9]+\.[0-9]+\.[0-9]+' action.yml | sed -E 's/.*lycheeVersion:\s*default:\s*(v[0-9]+\.[0-9]+\.[0-9]+).*/\1/') + lychee_version=$(awk '/lycheeVersion:/ {getline; getline; print}' action.yml | grep -Eo 'v[0-9]+\.[0-9]+\.[0-9]+') if [ -z "$lychee_version" ]; then echo "Error: Failed to extract lycheeVersion from action.yml" exit 1 fi echo "Extracted lycheeVersion: $lychee_version" - echo "action_lychee_version=$lychee_version" >> "$GITHUB_OUTPUT" + echo "action_lychee_version=$lychee_version" >> $GITHUB_OUTPUT - name: Compare versions id: compare-versions From 80a8e501e1a80414256b9b035897ba8bec38a56f Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:41:14 +0200 Subject: [PATCH 21/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index fe939c6..4f2906f 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -44,9 +44,9 @@ jobs: id: compare-versions run: | echo "Comparing versions..." - echo "Action lychee version: $action_lychee_version" + echo "Action lychee version: $lychee_version" echo "Latest release version: $release_version" - if [ "$action_lychee_version" != "$release_version" ]; then + if [ "$lychee_version" != "$release_version" ]; then echo "Versions do not match. Setting mismatch to true." echo "mismatch=true" >> $GITHUB_OUTPUT else From bd7e1968cf737dc1754b62f8c48fd4959b71923c Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:43:29 +0200 Subject: [PATCH 22/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 4f2906f..f6ecf6f 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -44,9 +44,11 @@ jobs: id: compare-versions run: | echo "Comparing versions..." - echo "Action lychee version: $lychee_version" + action_lychee_version="${{ steps.get-action-lychee-version.outputs.action_lychee_version }}" + release_version="${{ steps.get-lychee-release.outputs.release_version }}" + echo "Action lychee version: $action_lychee_version" echo "Latest release version: $release_version" - if [ "$lychee_version" != "$release_version" ]; then + if [ "$action_lychee_version" != "$release_version" ]; then echo "Versions do not match. Setting mismatch to true." echo "mismatch=true" >> $GITHUB_OUTPUT else From c983e6a9afb6939bb04d7e4cd935d2a7b19ead58 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:46:57 +0200 Subject: [PATCH 23/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index f6ecf6f..b0e64d5 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -17,7 +17,7 @@ jobs: name: Check lychee version steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Get current lychee release version id: get-lychee-release @@ -67,7 +67,7 @@ jobs: release_version: ${{ needs.check-lychee-version.outputs.release_version }} steps: - name: Checkout repository - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Create branch for update run: | @@ -82,9 +82,10 @@ jobs: git push origin update-lychee-version - name: Create Pull Request - uses: peter-evans/create-pull-request@v4 + uses: peter-evans/create-pull-request@v7 with: token: ${{ secrets.GITHUB_TOKEN }} + base: main branch: update-lychee-version title: "Update lycheeVersion to $release_version" body: "This PR updates the lycheeVersion to the latest release version $release_version." From 446052f5121cf888e05c07413cb64e5dbdc2a7e0 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:49:54 +0200 Subject: [PATCH 24/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index b0e64d5..fc82946 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -74,7 +74,7 @@ jobs: echo "Creating a new branch for the update..." git config --global user.name 'github-actions' git config --global user.email 'github-actions@github.com' - git checkout -b update-lychee-version + git checkout -b update-lychee-$release_version echo "Updating action.yml with the new lychee version..." sed -i "s/$action_lychee_version/$release_version/" action.yml git commit -am "Update lycheeVersion to $release_version" From 208b2610735a213bae80bfc7cd9bf9ea66d2de54 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:53:03 +0200 Subject: [PATCH 25/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index fc82946..bd0d520 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -65,6 +65,8 @@ jobs: env: action_lychee_version: ${{ needs.check-lychee-version.outputs.action_lychee_version }} release_version: ${{ needs.check-lychee-version.outputs.release_version }} + update_branch_name: "update-lychee-${{ needs.check-lychee-version.outputs.release_version }}" + steps: - name: Checkout repository uses: actions/checkout@v4 @@ -74,12 +76,13 @@ jobs: echo "Creating a new branch for the update..." git config --global user.name 'github-actions' git config --global user.email 'github-actions@github.com' - git checkout -b update-lychee-$release_version + git checkout -b $update_branch_name echo "Updating action.yml with the new lychee version..." sed -i "s/$action_lychee_version/$release_version/" action.yml git commit -am "Update lycheeVersion to $release_version" echo "Pushing the branch to the repository..." - git push origin update-lychee-version + git push origin $update_branch_name + echo "Branch $update_branch_name created and pushed successfully." - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 77c68f76a2edb33bc5edd212de2fc41d69e4d5ea Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 15:59:29 +0200 Subject: [PATCH 26/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index bd0d520..45fe774 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -57,6 +57,10 @@ jobs: fi create-pr: + permissions: + contents: write + pull-requests: write + needs: check-lychee-version runs-on: ubuntu-latest if: needs.check-lychee-version.outputs.mismatch == 'true' @@ -88,8 +92,8 @@ jobs: uses: peter-evans/create-pull-request@v7 with: token: ${{ secrets.GITHUB_TOKEN }} - base: main - branch: update-lychee-version + base: ${{ github.event.repository.default_branch }} + branch: $update_branch_name title: "Update lycheeVersion to $release_version" body: "This PR updates the lycheeVersion to the latest release version $release_version." labels: "automated pr" From f57aff75e0a6c08a091091e94d6b5b5a786d2b87 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:03:16 +0200 Subject: [PATCH 27/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 45fe774..1fe86f0 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -88,10 +88,13 @@ jobs: git push origin $update_branch_name echo "Branch $update_branch_name created and pushed successfully." + - name: Debug Default Branch + run: | + echo "Default branch is: ${{ github.event.repository.default_branch }}" + - name: Create Pull Request uses: peter-evans/create-pull-request@v7 with: - token: ${{ secrets.GITHUB_TOKEN }} base: ${{ github.event.repository.default_branch }} branch: $update_branch_name title: "Update lycheeVersion to $release_version" From 0d107f2996090c646df0e559da3178fa70e2ac4d Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:07:43 +0200 Subject: [PATCH 28/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 1fe86f0..09d68c3 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -77,20 +77,8 @@ jobs: - name: Create branch for update run: | - echo "Creating a new branch for the update..." - git config --global user.name 'github-actions' - git config --global user.email 'github-actions@github.com' - git checkout -b $update_branch_name echo "Updating action.yml with the new lychee version..." sed -i "s/$action_lychee_version/$release_version/" action.yml - git commit -am "Update lycheeVersion to $release_version" - echo "Pushing the branch to the repository..." - git push origin $update_branch_name - echo "Branch $update_branch_name created and pushed successfully." - - - name: Debug Default Branch - run: | - echo "Default branch is: ${{ github.event.repository.default_branch }}" - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 389c11ff7702dc0e0b6f51d716a2e3e7bc423a87 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:10:12 +0200 Subject: [PATCH 29/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 09d68c3..4b80f6c 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -84,8 +84,8 @@ jobs: uses: peter-evans/create-pull-request@v7 with: base: ${{ github.event.repository.default_branch }} - branch: $update_branch_name - title: "Update lycheeVersion to $release_version" + branch: ${{ env.update_branch_name }} + title: "Update lycheeVersion to ${{ env.release_version }}" body: "This PR updates the lycheeVersion to the latest release version $release_version." - labels: "automated pr" + labels: "automated-pr" assignees: arteiii From 527377532c470a17363ff86ee10fbf80af39ad82 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:12:14 +0200 Subject: [PATCH 30/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 4b80f6c..9d3c840 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -86,6 +86,6 @@ jobs: base: ${{ github.event.repository.default_branch }} branch: ${{ env.update_branch_name }} title: "Update lycheeVersion to ${{ env.release_version }}" - body: "This PR updates the lycheeVersion to the latest release version $release_version." + body: "This PR updates the lycheeVersion to the latest release version ${{ env.release_version }} ." labels: "automated-pr" assignees: arteiii From 6c43d00e778f75e334fe18b9a626dca08b0810a8 Mon Sep 17 00:00:00 2001 From: Arteiii <48642527+Arteiii@users.noreply.github.com> Date: Mon, 31 Mar 2025 14:13:01 +0000 Subject: [PATCH 31/45] [create-pull-request] automated change --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index 3591acb..b706f73 100644 --- a/action.yml +++ b/action.yml @@ -28,7 +28,7 @@ inputs: required: false lycheeVersion: description: "Use custom version of lychee link checker" - default: v0.18.0 + default: v0.18.1 required: false output: description: "Summary output file path" From 21257c491bb505add8e2f634e3683e8f1a2e4465 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:15:47 +0200 Subject: [PATCH 32/45] fixed workflow naming and dispatch --- .github/workflows/lychee-version.yml | 1 + .github/workflows/test.yml | 2 ++ .github/workflows/test_cache.yml | 12 ++++++++---- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 9d3c840..47cab1b 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -4,6 +4,7 @@ on: schedule: - cron: "0 0 * * 0" # every Sunday workflow_dispatch: + repository_dispatch: jobs: check-lychee-version: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f890573..50d1b58 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,3 +1,5 @@ +name: Test lychee-action + on: push: branches: diff --git a/.github/workflows/test_cache.yml b/.github/workflows/test_cache.yml index 4dafa94..2ec4d6d 100644 --- a/.github/workflows/test_cache.yml +++ b/.github/workflows/test_cache.yml @@ -1,8 +1,12 @@ +name: Test cache + on: - - repository_dispatch - - workflow_dispatch - - push - - pull_request + push: + branches: + - master + pull_request: + workflow_dispatch: + repository_dispatch: jobs: lychee-action: From be98a93b8f742a4640b3028b9d514e5f3736fadd Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:36:10 +0200 Subject: [PATCH 33/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 47cab1b..8fa970c 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -12,7 +12,7 @@ jobs: outputs: mismatch: ${{ steps.compare-versions.outputs.mismatch }} - action_lychee_version: ${{ steps.get-action-lychee-version.outputs.action_lychee_version }} + action_lychee_version: ${{ steps.get-action-lychee-version.outputs.result }} release_version: ${{ steps.get-lychee-release.outputs.release_version }} name: Check lychee version @@ -31,21 +31,15 @@ jobs: - name: Extract lycheeVersion from action.yml id: get-action-lychee-version - run: | - echo "Extracting lycheeVersion from action.yml..." - lychee_version=$(awk '/lycheeVersion:/ {getline; getline; print}' action.yml | grep -Eo 'v[0-9]+\.[0-9]+\.[0-9]+') - if [ -z "$lychee_version" ]; then - echo "Error: Failed to extract lycheeVersion from action.yml" - exit 1 - fi - echo "Extracted lycheeVersion: $lychee_version" - echo "action_lychee_version=$lychee_version" >> $GITHUB_OUTPUT + uses: mikefarah/yq@master + with: + cmd: yq '.inputs.lycheeVersion.default' action.yml - name: Compare versions id: compare-versions run: | echo "Comparing versions..." - action_lychee_version="${{ steps.get-action-lychee-version.outputs.action_lychee_version }}" + action_lychee_version="${{ steps.get-action-lychee-version.outputs.result }}" release_version="${{ steps.get-lychee-release.outputs.release_version }}" echo "Action lychee version: $action_lychee_version" echo "Latest release version: $release_version" From cef667aa5f86bdb147ccdaba252f2e86ff307b74 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:40:06 +0200 Subject: [PATCH 34/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 8fa970c..fc6c425 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -71,9 +71,9 @@ jobs: uses: actions/checkout@v4 - name: Create branch for update - run: | - echo "Updating action.yml with the new lychee version..." - sed -i "s/$action_lychee_version/$release_version/" action.yml + uses: mikefarah/yq@master + with: + cmd: yq -i '.inputs.lycheeVersion.default = env.release_version' action.yml - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 98a1d87ffd426576dbf46c9a777de7faecb72e99 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:41:24 +0200 Subject: [PATCH 35/45] test update --- .github/workflows/lychee-version.yml | 1 - action.yml | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index fc6c425..8565daf 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -78,7 +78,6 @@ jobs: - name: Create Pull Request uses: peter-evans/create-pull-request@v7 with: - base: ${{ github.event.repository.default_branch }} branch: ${{ env.update_branch_name }} title: "Update lycheeVersion to ${{ env.release_version }}" body: "This PR updates the lycheeVersion to the latest release version ${{ env.release_version }} ." diff --git a/action.yml b/action.yml index b706f73..3591acb 100644 --- a/action.yml +++ b/action.yml @@ -28,7 +28,7 @@ inputs: required: false lycheeVersion: description: "Use custom version of lychee link checker" - default: v0.18.1 + default: v0.18.0 required: false output: description: "Summary output file path" From 52acf311fc182d5568d87b7731474f133b5c08dd Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:41:59 +0200 Subject: [PATCH 36/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 8565daf..9407b90 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -1,4 +1,4 @@ -name: "Check Lychee Version and Create PR" +name: "Update Lychee Default Version" on: schedule: From f607cf472761b2440002e1e69e9c76814d69b768 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:43:47 +0200 Subject: [PATCH 37/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 9407b90..357577c 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -73,7 +73,7 @@ jobs: - name: Create branch for update uses: mikefarah/yq@master with: - cmd: yq -i '.inputs.lycheeVersion.default = env.release_version' action.yml + cmd: yq -i '.inputs.lycheeVersion.default = ${{ env.release_version }}' action.yml - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 6e15e8dd5a53bcba3f9547e3e205e3b93d496021 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:48:42 +0200 Subject: [PATCH 38/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 357577c..2b71dde 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -73,7 +73,7 @@ jobs: - name: Create branch for update uses: mikefarah/yq@master with: - cmd: yq -i '.inputs.lycheeVersion.default = ${{ env.release_version }}' action.yml + cmd: yq -i '.inputs.lycheeVersion.default = $release_version' action.yml - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 99a1097f0c6b4c3b21358b9576f8c137f5ed7bc5 Mon Sep 17 00:00:00 2001 From: Arteiii <48642527+Arteiii@users.noreply.github.com> Date: Mon, 31 Mar 2025 14:49:22 +0000 Subject: [PATCH 39/45] [create-pull-request] automated change --- action.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/action.yml b/action.yml index 3591acb..b40279c 100644 --- a/action.yml +++ b/action.yml @@ -1,6 +1,5 @@ name: "Lychee Broken Link Checker" description: "Quickly check links in Markdown, HTML, and text files" - inputs: args: description: "Lychee arguments (https://github.com/lycheeverse/lychee#commandline-parameters)" @@ -46,12 +45,10 @@ inputs: description: "Directory to run lychee in" default: "." required: false - outputs: exit_code: description: "The exit code returned from Lychee" value: ${{ steps.run-lychee.outputs.exit_code }} - runs: using: "composite" steps: @@ -60,7 +57,6 @@ runs: echo "$HOME/.local/bin" >> "$GITHUB_PATH" mkdir -p "$HOME/.local/bin" shell: bash - - name: Clean up existing lychee files run: | # Remove any existing lychee binaries or archives to prevent conflicts @@ -68,7 +64,6 @@ runs: rm -rf lychee rm -f "${{ steps.lychee-filename.outputs.filename }}" shell: bash - - name: Download and extract lychee id: lychee-setup run: | @@ -99,12 +94,10 @@ runs: env: LYCHEE_VERSION: ${{ inputs.lycheeVersion }} shell: bash - - name: Install lychee run: | install -t "$HOME/.local/bin" -D lychee shell: bash - - name: Clean up installation files run: | # Remove the downloaded archive and any unnecessary files after installation @@ -112,7 +105,6 @@ runs: shopt -s extglob rm -f lychee!(*-bin|*-lib|*.toml) shell: bash - - name: Run Lychee id: run-lychee working-directory: ${{ inputs.workingDirectory }} From 8b8672a25459533b2fcb849e1aaa203e5658f3a3 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:55:36 +0200 Subject: [PATCH 40/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 2b71dde..5eb4199 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -70,10 +70,10 @@ jobs: - name: Checkout repository uses: actions/checkout@v4 - - name: Create branch for update + - name: Update lycheeVersion in action.yml uses: mikefarah/yq@master with: - cmd: yq -i '.inputs.lycheeVersion.default = $release_version' action.yml + cmd: yq -i ".inputs.lycheeVersion.default = \"${{ env.release_version }}\"" action.yml - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From af4749258d78346dfb7bbf37a501a8f21f4f32e6 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 16:57:09 +0200 Subject: [PATCH 41/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 5eb4199..adcf755 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -73,7 +73,7 @@ jobs: - name: Update lycheeVersion in action.yml uses: mikefarah/yq@master with: - cmd: yq -i ".inputs.lycheeVersion.default = \"${{ env.release_version }}\"" action.yml + cmd: yq -i ".inputs.lycheeVersion.default = ${{ env.release_version }}" action.yml - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 89656d620e7c85847cc52bd3d8272842a7471885 Mon Sep 17 00:00:00 2001 From: Ben Date: Mon, 31 Mar 2025 17:00:25 +0200 Subject: [PATCH 42/45] Update lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index adcf755..d7b60ad 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -73,7 +73,7 @@ jobs: - name: Update lycheeVersion in action.yml uses: mikefarah/yq@master with: - cmd: yq -i ".inputs.lycheeVersion.default = ${{ env.release_version }}" action.yml + cmd: yq -i '.inputs.lycheeVersion.default = "${{ env.release_version }}"' action.yml - name: Create Pull Request uses: peter-evans/create-pull-request@v7 From 54337ed454657218c397a6000c6e9b6a3e568e79 Mon Sep 17 00:00:00 2001 From: Arteiii <48642527+Arteiii@users.noreply.github.com> Date: Mon, 31 Mar 2025 15:02:00 +0000 Subject: [PATCH 43/45] [create-pull-request] automated change --- action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yml b/action.yml index b40279c..ac95673 100644 --- a/action.yml +++ b/action.yml @@ -27,7 +27,7 @@ inputs: required: false lycheeVersion: description: "Use custom version of lychee link checker" - default: v0.18.0 + default: v0.18.1 required: false output: description: "Summary output file path" From 7600e8f72c54d0be37239c40af4ac64ac3c36ea0 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 1 Apr 2025 08:04:31 +0200 Subject: [PATCH 44/45] Aktualisieren von lychee-version.yml --- .github/workflows/lychee-version.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index d7b60ad..9284cec 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -82,4 +82,4 @@ jobs: title: "Update lycheeVersion to ${{ env.release_version }}" body: "This PR updates the lycheeVersion to the latest release version ${{ env.release_version }} ." labels: "automated-pr" - assignees: arteiii + assignees: mre From 397e293f23db6d401c7ef0762e4aa8630100146e Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 1 Apr 2025 16:16:50 +0200 Subject: [PATCH 45/45] Update .github/workflows/lychee-version.yml Co-authored-by: Matthias Endler --- .github/workflows/lychee-version.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/lychee-version.yml b/.github/workflows/lychee-version.yml index 9284cec..bc8aa26 100644 --- a/.github/workflows/lychee-version.yml +++ b/.github/workflows/lychee-version.yml @@ -83,3 +83,4 @@ jobs: body: "This PR updates the lycheeVersion to the latest release version ${{ env.release_version }} ." labels: "automated-pr" assignees: mre + reviewers: Arteiii,thomas-zahner