Skip to content

Commit

Permalink
Update comment-issue.js
Browse files Browse the repository at this point in the history
  • Loading branch information
t-will-gillis authored Oct 22, 2023
1 parent 0cd9666 commit 976d384
Showing 1 changed file with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ async function main({ g, c }, newIssueNumber) {
// Issue #2607 is the `Dev/PM Agenda and Notes`
let agendaAndNotesIssueNumber = 336;
await commentOnIssue(agendaAndNotesIssueNumber, newIssueNumber);
await commentToCloseIssue(agendaAndNotesIssueNumber);
}

// Add a link to the `Review Inactive Team Members` issue
Expand All @@ -25,4 +26,17 @@ const commentOnIssue = async (agendaAndNotesIssueNumber, newIssueNumber) => {
});
};

// Add a comment on the issue to automatically close it
const commentToCloseIssue = async (agendaAndNotesIssueNumber) => {
const owner = "t-will-gillis";
const repo = "website";
await github.rest.issues.createComment({
owner,
repo,
issue_number: agendaAndNotesIssueNumber,
body: `Close #${agendaAndNotesIssueNumber}`,
});
};


module.exports = main;

0 comments on commit 976d384

Please sign in to comment.