You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: .github/workflows/auto-close.yml
+18-2Lines changed: 18 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -24,6 +24,11 @@ on:
24
24
options:
25
25
- 'false'
26
26
- 'true'
27
+
grace_period_minutes:
28
+
description: 'Grace period in minutes before a potential-duplicate issue is labelled duplicate and closed (overrides config). Leave empty to use the configured default.'
--title "Auto-closer grace period and human-activity E2E test" \
310
+
--body "This issue is created by the E2E pipeline to verify the auto-closer detects expired grace periods and correctly skips issues with human activity signals.")
Copy file name to clipboardExpand all lines: README.md
+44Lines changed: 44 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -220,6 +220,50 @@ Notes:
220
220
- `llm.api_key`can be omitted if `GEMINI_API_KEY` is set.
221
221
- You can override the model at runtime with `LLM_MODEL`.
222
222
223
+
### `simili auto-close`
224
+
225
+
Scan all open issues labelled `potential-duplicate` and close those whose grace period has expired with no human activity. Closed issues are relabelled from `potential-duplicate` → `duplicate`.
226
+
227
+
```bash
228
+
simili auto-close --repo owner/repo --grace-period-minutes 60
229
+
```
230
+
231
+
**Flags:**
232
+
- `--repo` (required): Target repository (`owner/name`); falls back to `GITHUB_REPOSITORY` env var
233
+
- `--grace-period-minutes`: Override the grace period in minutes for this run (see precedence below)
234
+
- `--dry-run`: Print what would be closed without making any changes
235
+
- `--config`: Path to `simili.yaml` (auto-discovered if omitted)
236
+
237
+
**Grace period precedence** (highest → lowest):
238
+
239
+
| Source | How to set |
240
+
|--------|-----------|
241
+
| `--grace-period-minutes` CLI flag | Pass at runtime — overrides everything |
242
+
| `auto_close.grace_period_hours` in `simili.yaml` | Persistent per-repo config |
243
+
| Built-in default | 72 hours (3 days) |
244
+
245
+
**`simili.yaml` configuration:**
246
+
247
+
```yaml
248
+
auto_close:
249
+
grace_period_hours: 48 # default: 72
250
+
dry_run: false
251
+
```
252
+
253
+
**Human activity signals** — any of these prevent auto-close:
254
+
1. A negative reaction (👎 or 😕) on the bot's triage comment by a non-bot user.
255
+
2. The issue was reopened by a human after the `potential-duplicate` label was applied.
256
+
3. A non-bot comment posted after the label was applied.
257
+
258
+
**GitHub Actions usage** — the `auto-close.yml` workflow runs daily at 10:00 UTC and can be triggered manually via `workflow_dispatch` with an optional `grace_period_minutes` input:
259
+
260
+
```yaml
261
+
# Trigger from GitHub UI or gh CLI:
262
+
gh workflow run auto-close.yml -f grace_period_minutes=60 -f dry_run=false
263
+
```
264
+
265
+
Leaving `grace_period_minutes` empty uses the value from `simili.yaml` (or the 72 h default).
0 commit comments