From 0dc45bc24eb351e3381d210ef85b5272a803d8c4 Mon Sep 17 00:00:00 2001 From: Federico Kunze <31522760+fedekunze@users.noreply.github.com> Date: Tue, 28 Jul 2020 16:04:06 +0200 Subject: [PATCH] actions: stale bot (#415) * actions: stale bot * filter diff on build * fix * more fixes --- .github/workflows/build.yml | 8 ++++++++ .github/workflows/stale.yml | 22 ++++++++++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 .github/workflows/stale.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3671c0aa..19a45dd9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -17,5 +17,13 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + - uses: technote-space/get-diff-action@v1 + id: git_diff + with: + SUFFIX_FILTER: | + .go + .mod + .sum - run: | make build + if: "env.GIT_DIFF != ''" diff --git a/.github/workflows/stale.yml b/.github/workflows/stale.yml new file mode 100644 index 00000000..6cb737e7 --- /dev/null +++ b/.github/workflows/stale.yml @@ -0,0 +1,22 @@ +name: "Close stale issues & pull requests" +on: + schedule: + - cron: "0 0 * * *" + +jobs: + stale: + runs-on: ubuntu-latest + steps: + - uses: actions/stale@v3 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} + stale-pr-message: "This pull request has been automatically marked as stale because it has not had + recent activity. It will be closed in 7 days-before-close if no further activity occurs. Thank you + for your contributions." + stale-issue-message: "This issue is stale because it has been open 30 days with no activity. Remove `stale` label or comment or this will be closed in 7 days." + days-before-stale: 21 + days-before-close: 7 + exempt-issue-labels: "Status: On Ice, Status: Blocked, Type: Bug, Type: Security, Type: Meta-Issue, Type: Enhancement, Epic" + exempt-pr-labels: "Status: On Ice, Status: Blocked, Type: Bug, Type: Security, Type: Meta-Issue, Type: Enhancement, Epic" + stale-pr-label: "stale" + stale-issue-label: "stale"