From a8546a281fc67f75660b88edec36e2de6cb0671d Mon Sep 17 00:00:00 2001 From: devlooped-bot Date: Mon, 2 Sep 2024 19:28:05 +0000 Subject: [PATCH] =?UTF-8?q?=E2=AC=86=EF=B8=8F=20Bump=20files=20with=20dotn?= =?UTF-8?q?et-file=20sync=20#=20devlooped/oss?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Improve triage actions on issues https://github.com/devlooped/oss/commit/33000c0 --- .github/workflows/{stale.yml => triage.yml} | 56 +++++++++++++++++---- .netconfig | 8 +-- readme.md | 1 + 3 files changed, 52 insertions(+), 13 deletions(-) rename .github/workflows/{stale.yml => triage.yml} (55%) diff --git a/.github/workflows/stale.yml b/.github/workflows/triage.yml similarity index 55% rename from .github/workflows/stale.yml rename to .github/workflows/triage.yml index ebe04b3c8..56ff299a2 100644 --- a/.github/workflows/stale.yml +++ b/.github/workflows/triage.yml @@ -1,4 +1,4 @@ -name: 'stale' +name: 'triage' on: schedule: - cron: '42 0 * * *' @@ -6,19 +6,27 @@ on: workflow_dispatch: # Manual triggering through the GitHub UI, API, or CLI inputs: + daysBeforeClose: + description: "Days before closing stale or need info issues" + required: true + default: "30" daysBeforeStale: + description: "Days before labeling stale" required: true default: "180" - daysBeforeClose: + daysSinceClose: + description: "Days since close to lock" required: true default: "30" - operationsPerRun: + daysSinceUpdate: + description: "Days since update to lock" required: true - default: "4000" + default: "30" permissions: actions: write # For managing the operation state cache issues: write + contents: read jobs: stale: @@ -30,10 +38,12 @@ jobs: shell: pwsh if: github.event_name != 'workflow_dispatch' env: - GH_TOKEN: ${{ github.token }} + GH_TOKEN: ${{ secrets.DEVLOOPED_TOKEN }} run: | # add random sleep since we run on fixed schedule - sleep (get-random -max 60) + $wait = get-random -max 180 + echo "Waiting random $wait seconds to start" + sleep $wait # get currently authenticated user rate limit info $rate = gh api rate_limit | convertfrom-json | select -expandproperty rate # if we don't have at least 100 requests left, wait until reset @@ -45,8 +55,9 @@ jobs: echo "Rate limit has reset to $($rate.remaining) requests" } - - name: ✏️ label - uses: actions/stale@v9 + - name: ✏️ stale labeler + # pending merge: https://github.com/actions/stale/pull/1176 + uses: kzu/stale@c8450312ba97b204bf37545cb249742144d6ca69 with: ascending: true # Process the oldest issues first stale-issue-label: 'stale' @@ -59,7 +70,34 @@ jobs: days-before-stale: ${{ fromJson(inputs.daysBeforeStale || 180) }} days-before-close: ${{ fromJson(inputs.daysBeforeClose || 30 ) }} days-before-pr-close: -1 # Do not close PRs labeled as 'stale' - operations-per-run: ${{ fromJson(inputs.operationsPerRun || 4000 )}} exempt-all-milestones: true exempt-all-assignees: true exempt-issue-labels: priority,sponsor,backed + exempt-authors: kzu + + - name: 🤘 checkout actions + uses: actions/checkout@v4 + with: + repository: 'microsoft/vscode-github-triage-actions' + ref: v42 + + - name: ⚙ install actions + run: npm install --production + + - name: 🔒 issues locker + uses: ./locker + with: + token: ${{ secrets.DEVLOOPED_TOKEN }} + ignoredLabel: priority + daysSinceClose: ${{ fromJson(inputs.daysSinceClose || 30) }} + daysSinceUpdate: ${{ fromJson(inputs.daysSinceUpdate || 30) }} + + - name: 🔒 need info closer + uses: ./needs-more-info-closer + with: + token: ${{ secrets.DEVLOOPED_TOKEN }} + label: 'need info' + closeDays: ${{ fromJson(inputs.daysBeforeClose || 30) }} + closeComment: "This issue has been closed automatically because it needs more information and has not had recent activity.\n\nHappy Coding!" + pingDays: 80 + pingComment: "Hey @${assignee}, this issue might need further attention.\n\n@${author}, you can help us out by closing this issue if the problem no longer exists, or adding more information." \ No newline at end of file diff --git a/.netconfig b/.netconfig index 2d5ace7ce..4a4aa0491 100644 --- a/.netconfig +++ b/.netconfig @@ -101,8 +101,8 @@ [file "src/nuget.config"] url = https://github.com/devlooped/oss/blob/main/src/nuget.config skip -[file ".github/workflows/stale.yml"] - url = https://github.com/devlooped/oss/blob/main/.github/workflows/stale.yml - sha = 68f4c7321b9fda30af59c4797cd557d321e97256 - etag = a6338e345de8ab01bc2630cb5b48d9cd9b4b7349159abb6db595956fb8c0315e +[file ".github/workflows/triage.yml"] + url = https://github.com/devlooped/oss/blob/main/.github/workflows/triage.yml + sha = 33000c0c4ab4eb4e0e142fa54515b811a189d55c + etag = 013a47739e348f06891f37c45164478cca149854e6cd5c5158e6f073f852b61a weak diff --git a/readme.md b/readme.md index fd589af98..8e60ea739 100644 --- a/readme.md +++ b/readme.md @@ -145,6 +145,7 @@ We appreciate deeply any feedback that you may have! Feel free to participate in [![ChilliCream](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/ChilliCream.png "ChilliCream")](https://github.com/ChilliCream) [![4OTC](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/4OTC.png "4OTC")](https://github.com/4OTC) [![Vincent Limo](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/v-limo.png "Vincent Limo")](https://github.com/v-limo) +[![Brooke Hamilton](https://raw.githubusercontent.com/devlooped/sponsors/main/.github/avatars/brooke-hamilton.png "Brooke Hamilton")](https://github.com/brooke-hamilton)