From e7526be6a09a2e52d2b9796bdca460ce324e08be Mon Sep 17 00:00:00 2001 From: Aditi Verma Date: Tue, 29 Oct 2024 21:59:33 +0530 Subject: [PATCH 1/4] Create detect-duplicate.yml --- .github/workflows/detect-duplicate.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/detect-duplicate.yml diff --git a/.github/workflows/detect-duplicate.yml b/.github/workflows/detect-duplicate.yml new file mode 100644 index 0000000..32f798f --- /dev/null +++ b/.github/workflows/detect-duplicate.yml @@ -0,0 +1,25 @@ +name: Duplicate Issue Detection + +on: + issues: + types: [opened] + +jobs: + detect-duplicate: + runs-on: ubuntu-latest + + steps: + - name: Check out the repository + uses: actions/checkout@v2 + + - name: Run Duplicate Issue Checker + uses: ahmadnassri/action-similar-issue@v1 + id: duplicate-check + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + min-confidence: 0.8 # Confidence level for similarity (80%) + + - name: Handle Duplicate Issues + if: steps.duplicate-check.outputs.similar == 'true' + run: | + gh issue close ${{ github.event.issue.number }} -c "Duplicate issue detected. Please refer to #${{ steps.duplicate-check.outputs.duplicate_issue_number }}." From 80c6bdde553b75ec5b75180ad00e15fd11943379 Mon Sep 17 00:00:00 2001 From: Aditi Verma Date: Tue, 29 Oct 2024 22:07:13 +0530 Subject: [PATCH 2/4] Create greeting-new-issue.yml --- .github/workflows/greeting-new-issue.yml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 .github/workflows/greeting-new-issue.yml diff --git a/.github/workflows/greeting-new-issue.yml b/.github/workflows/greeting-new-issue.yml new file mode 100644 index 0000000..7cf864d --- /dev/null +++ b/.github/workflows/greeting-new-issue.yml @@ -0,0 +1,15 @@ +name: Greetings + +on: [pull_request_target, issues] + +jobs: + greeting: + runs-on: ubuntu-latest + permissions: + issues: write + pull-requests: write + steps: + - uses: actions/first-interaction@v1 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + issue-message: "Hi there! Thanks for opening this issue. We appreciate your contribution to this open-source project. We aim to respond or assign your issue as soon as possible. Stay awesome!" From 11352875192e88aee7f9dfd877d74119621ef0f9 Mon Sep 17 00:00:00 2001 From: Aditi Verma Date: Tue, 29 Oct 2024 22:27:50 +0530 Subject: [PATCH 3/4] Create auto-comment-issue.yml --- .github/workflows/auto-comment-issue.yml | 30 ++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 .github/workflows/auto-comment-issue.yml diff --git a/.github/workflows/auto-comment-issue.yml b/.github/workflows/auto-comment-issue.yml new file mode 100644 index 0000000..693505d --- /dev/null +++ b/.github/workflows/auto-comment-issue.yml @@ -0,0 +1,30 @@ +name: Issue Opened and Closed Comment + +on: + issues: + types: [opened, closed] + +jobs: + comment-on-issue: + runs-on: ubuntu-latest + + steps: + - name: Check out the repository + uses: actions/checkout@v2 + + - name: Comment on Issue Opened + if: ${{ github.event.action == 'opened' }} + uses: actions-ecosystem/action-create-comment@v1 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + issue_number: ${{ github.event.issue.number }} + body: | + Thanks for opening this issue! We appreciate your contribution. Please make sure you’ve provided all the necessary details and screenshots, and don't forget to follow our [Guidelines](https://github.com/OWNER/REPO/CONTRIBUTING.md) and Code of Conduct. Happy coding! 🚀 + - name: Comment on Issue Closed + if: ${{ github.event.action == 'closed' }} + uses: actions-ecosystem/action-create-comment@v1 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + issue_number: ${{ github.event.issue.number }} + body: | + This issue has been successfully closed. Thank you for your contribution and helping us improve the project! If you have any more ideas or run into other issues, feel free to open a new one. Happy coding! 🚀 From 5faa00705a8101515f6710330ffe7296c93deaa4 Mon Sep 17 00:00:00 2001 From: Aditi Verma Date: Tue, 29 Oct 2024 22:28:41 +0530 Subject: [PATCH 4/4] Create auto-label.yml --- .github/workflows/auto-label.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 .github/workflows/auto-label.yml diff --git a/.github/workflows/auto-label.yml b/.github/workflows/auto-label.yml new file mode 100644 index 0000000..8e43a93 --- /dev/null +++ b/.github/workflows/auto-label.yml @@ -0,0 +1,22 @@ +name: Auto-label Issues and Pull Requests + +on: + issues: + types: [opened] + pull_request: + types: [opened] + +jobs: + add-labels: + runs-on: ubuntu-latest + + steps: + - name: Check out the repository + uses: actions/checkout@v2 + + - name: Add Labels to Issue or Pull Request + uses: actions-ecosystem/action-add-labels@v1 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + labels: "gssoc-ext, hacktoberfest-accepted" + issue_number: ${{ github.event.issue.number || github.event.pull_request.number }}