From 9bbc0e34360344e7dbdfbfb90552755a51241661 Mon Sep 17 00:00:00 2001 From: Craig Loewen Date: Wed, 15 Nov 2023 16:27:45 -0500 Subject: [PATCH 1/2] Added similar issues bot --- .github/workflows/similar-issues-bot.yml | 32 ++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 .github/workflows/similar-issues-bot.yml diff --git a/.github/workflows/similar-issues-bot.yml b/.github/workflows/similar-issues-bot.yml new file mode 100644 index 0000000000..5ae659578d --- /dev/null +++ b/.github/workflows/similar-issues-bot.yml @@ -0,0 +1,32 @@ +name: GitGudSimilarIssues comments + +on: + issues: + types: [opened] + +jobs: + getsimilarissues: + runs-on: ubuntu-latest + outputs: + message: ${{ steps.getbody.outputs.message }} + steps: + - uses: actions/checkout@v2 + - id: getbody + uses: craigloewen-msft/GitGudSimilarIssues@main + with: + issuetitle: ${{ github.event.issue.title }} + repo: ${{ github.repository }} + similaritytolerance: "0.75" + add-comment: + needs: getsimilarissues + runs-on: ubuntu-latest + permissions: + issues: write + steps: + - name: Add comment + run: gh issue comment "$NUMBER" --repo "$REPO" --body "$BODY" + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + NUMBER: ${{ github.event.issue.number }} + REPO: ${{ github.repository }} + BODY: ${{ needs.getsimilarissues.outputs.message }} From c98fe6926c25601c88fb41db0b1d04ed6fca2c3d Mon Sep 17 00:00:00 2001 From: Craig Loewen Date: Tue, 28 Nov 2023 17:28:21 -0500 Subject: [PATCH 2/2] Update similar-issues-bot.yml --- .github/workflows/similar-issues-bot.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/similar-issues-bot.yml b/.github/workflows/similar-issues-bot.yml index 5ae659578d..4ea86d4042 100644 --- a/.github/workflows/similar-issues-bot.yml +++ b/.github/workflows/similar-issues-bot.yml @@ -17,6 +17,10 @@ jobs: issuetitle: ${{ github.event.issue.title }} repo: ${{ github.repository }} similaritytolerance: "0.75" + commentBody: | + Hi I'm an AI powered bot that finds similar issues based off the issue title. + + Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one. Thank you! add-comment: needs: getsimilarissues runs-on: ubuntu-latest