From c0b127bf83c4ac975c8fd0849acd5f68718ca0ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antal=20J=C3=A1nos=20Monori?= Date: Tue, 23 Nov 2021 10:14:28 +0000 Subject: [PATCH] Add stale bot to manage the Issues/PRs automatically (#28) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Inactive Issues that are labeled with 'awaiting-feedback' will get marked as 'stale' after a period of time, then closed - Inactive PRs that are not in draft, or labeled with 'work-in-progress' or 'dependencies' will get marked as 'stale' after a period of time, then closed - Added dependabot support for GitHub Actions to keep our actions up-to-date Signed-off-by: Antal János Monori --- .github/dependabot.yml | 5 +++++ .github/workflows/stale.yml | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 .github/workflows/stale.yml diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 16ac3ac..b55c23f 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,6 +1,11 @@ version: 2 updates: - package-ecosystem: gradle + directory: "/" + schedule: + interval: weekly + open-pull-requests-limit: 5 + - package-ecosystem: "github-actions" directory: "/" schedule: interval: weekly diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml new file mode 100644 index 0000000..173b232 --- /dev/null +++ b/.github/workflows/stale.yml @@ -0,0 +1,33 @@ +name: Maintenance + +permissions: + issues: write + pull-requests: write + +on: + schedule: + - cron: '30 1 * * *' + +jobs: + stale: + runs-on: ubuntu-latest + steps: + - uses: actions/stale@v4 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + + stale-issue-message: 'This issue has been automatically marked as stale because it has not had any recent activity. It will be closed if no further activity occurs. Thank you for your contributions.' + close-issue-message: 'This issue has now been closed. Please raise a new Issue instead of re-opening existing ones, unless you believe this was closed by accident.' + days-before-issue-stale: 31 + days-before-issue-close: 7 + stale-issue-label: 'stale' + only-issue-labels: 'awaiting-feedback' + exempt-issue-labels: 'confirmed' + + stale-pr-message: 'This pull request has been automatically marked as stale because it has not had any recent activity. It will be closed if no further activity occurs. Thank you for your contributions.' + close-pr-message: 'This pull request has now been closed. If you want to continue working on it or you believe it has been closed by accident, feel free to re-open it.' + days-before-pr-stale: 31 + days-before-pr-close: 7 + stale-pr-label: 'stale' + exempt-pr-labels: 'work-in-progress,dependencies' + exempt-draft-pr: true