From d6919ca536bab55188cfb5bc3d656de50f12546d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sandro=20J=C3=A4ckel?= Date: Tue, 19 Nov 2024 18:33:50 +0100 Subject: [PATCH] Drop .git suffix from custom urls --- action.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/action.yaml b/action.yaml index fdefd32..740bfed 100644 --- a/action.yaml +++ b/action.yaml @@ -39,7 +39,7 @@ runs: locked="$(echo "$in" | jq -r .path | sed -e "s|^/|.\"|" -e "s/\(.\)\//\1\"\.\"/g" -e "s|\.\"rev$||g")"; \ old_rev="$(jq -r "$locked.rev" '"$before_flake_lock"')"; \ new_rev="$(echo "$in" | jq -r .value)"; \ - path="$(jq -r "$locked | \"\(if .type == \"github\" then \"https://\(.host // \"github.com\")/\(.owner)/\(.repo)\" else if .type == \"git\" then .url else \"error\" end end)/compare\"" flake.lock)"; \ + path="$(jq -r "$locked | \"\(if .type == \"github\" then \"https://\(.host // \"github.com\")/\(.owner)/\(.repo)\" else if .type == \"git\" then .url | sub(\".git$\"; \"\") else \"error\" end end)/compare\"" flake.lock)"; \ echo "- $path/$old_rev...$new_rev" \ ' "" >> comment.md