From a7ad1647aa2ab35d04eb5e0912556cbcfc17dfc0 Mon Sep 17 00:00:00 2001 From: pgijsbertsen <117165507+pgijsbertsen@users.noreply.github.com> Date: Fri, 3 Apr 2026 10:11:09 +0200 Subject: [PATCH] chore: Only use plan summary in comment --- .forgejo/workflows/tofu-plan-k8s-wheatley.yaml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml b/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml index fd629b8..686ca56 100644 --- a/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml +++ b/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml @@ -74,11 +74,13 @@ jobs:
Show Plan ``` - ${{ steps.plan.outputs.stdout }} + PLAN_PLACEHOLDER ```
run: | + filtered_plan=$(echo "${{ steps.plan.outputs.stdout }}" | awk '/Refreshing state/{found=0} /^$/{if(!found)print; next} {if(found)print} /Refreshing state/{found=1}' | sed '/./,$!d') + COMMENT_BODY="${COMMENT_BODY//'PLAN_PLACEHOLDER'/$filtered_plan}" payload=$(jq -Rs --arg body "$COMMENT_BODY" '{body: $body}' <<< "$COMMENT_BODY") existing_comment=$(curl -s \