diff --git a/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml b/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml index 686ca56..24f5731 100644 --- a/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml +++ b/.forgejo/workflows/tofu-plan-k8s-wheatley.yaml @@ -79,7 +79,7 @@ jobs: 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') + filtered_plan=$(echo "${{ steps.plan.outputs.stdout }}" | grep -vE '^\s*(module\.|data\.|resource\.).+: (Reading\.\.\.|Read complete after|Refreshing state)' | sed '/./,$!d') COMMENT_BODY="${COMMENT_BODY//'PLAN_PLACEHOLDER'/$filtered_plan}" payload=$(jq -Rs --arg body "$COMMENT_BODY" '{body: $body}' <<< "$COMMENT_BODY")