diff --git a/action.yml b/action.yml index 6c9d264..6b335c3 100644 --- a/action.yml +++ b/action.yml @@ -78,6 +78,11 @@ inputs: description: "The GitHub access token (e.g. secrets.GITHUB_TOKEN) used to create or update the comment. This defaults to {{ github.token }}." default: "${{ github.token }}" required: false +outputs: + previous_comment_id: + description: "ID of previous comment, if found" + created_comment_id: + description: "ID of newly created comment, if any" runs: using: "node16" main: "dist/index.js" diff --git a/src/comment.ts b/src/comment.ts index da70951..b6bad34 100644 --- a/src/comment.ts +++ b/src/comment.ts @@ -115,7 +115,7 @@ export async function createComment( if (!body && !previousBody) return core.warning("Comment body cannot be blank") - await octokit.rest.issues.createComment({ + let x = await octokit.rest.issues.createComment({ ...repo, issue_number, body: previousBody