From a9b422c73773a73e6346a17d3974a93f86daaf19 Mon Sep 17 00:00:00 2001 From: MaxymVlasov Date: Thu, 13 Feb 2025 02:36:58 +0200 Subject: [PATCH] cleanup --- .github/workflows/test.yml | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b9ee0ee..5401074 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -209,19 +209,11 @@ jobs: 'sort_by(.created_at) | reverse | .[0] | select(.body | contains("Dive Summary")) | .id') echo "Comment ID: $comment_id" - # Create a review comment and mark it as resolved - review_comment_id=$(gh api "repos/${{ github.repository }}/pulls/${pr_number}/comments" \ - -f body="Marking as resolved" \ - -f commit_id=$(git rev-parse HEAD) \ - -f path="path/to/file" \ - -f position=1 \ - --jq '.id') - - if [ -z "$review_comment_id" ]; then - echo "Failed to create review comment" + if [ -z "$comment_id" ]; then + echo "Expected comment not found in PR" exit 1 fi - # Mark the review comment as resolved - gh api -X PATCH "repos/${{ github.repository }}/pulls/comments/${review_comment_id}" \ - -f state="resolved" + # Delete the comment after verification + gh api -X DELETE "repos/${{ github.repository }}/issues/comments/${comment_id}" + echo "Comment deleted"