Installs GitHub Actions that run the contributor side of an open source repo without a maintainer in the loop - self-serve issue claiming with /assign or plain-language requests and a per-person cap, reminders and auto-unassign for idle claims, welcome messages for first issues and PRs, thanks and next-issue suggestions on merge, PR labels by type/area/size/first-timer, linked-issue checks, duplicate issue hints, a stale bot that never closes PRs waiting on review, monthly contributor shoutou...
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Magnet Bots?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/priyanshu-byte-coder-magnet-bots)
---
name: magnet-bots
description: Installs GitHub Actions that run the contributor side of an open source repo without a maintainer in the loop - self-serve issue claiming with /assign or plain-language requests and a per-person cap, reminders and auto-unassign for idle claims, welcome messages for first issues and PRs, thanks and next-issue suggestions on merge, PR labels by type/area/size/first-timer, linked-issue checks, duplicate issue hints, a stale bot that never closes PRs waiting on review, monthly contributor shoutouts, and per-program label tracking for GSSoC/SWoC/WOCS-style programs. Use when asked to automate issue assignment, add contributor bots or workflows, stop issue hoarding, or set up labels and points for an open source program.
license: MIT
metadata:
author: Priyanshu Doshi
repo: https://github.com/Priyanshu-byte-coder/contributor-magnet
---
# Magnet bots
Eleven small workflows, each one a job maintainers otherwise do by hand for every new contributor. All are `actions/github-script` with the config in an `env:` block at the top, no third-party apps, no secrets beyond the default `GITHUB_TOKEN`.
| Bot | File | What it does |
|---|---|---|
| claim | `magnet-claim.yml` | `/assign`, "can I work on this?" and similar get the commenter assigned if the issue is free. Cap of 5 open claims per person (maintainers exempt), `/unassign`, blocked and `first-timers-only` rules |
| unassign-idle | `magnet-unassign-idle.yml` | Daily: reminder on day 5, unassign on day 7 without a linked PR. The assignee's own comments reset the clock |
| welcome | `magnet-welcome.yml` | First issue and first PR get a short welcome with what happens next |
| merged-thanks | `magnet-merged-thanks.yml` | On merge: first-merge celebration, next-issue links, one star ask (first merge only, skipped if already starred) |
| stale | `magnet-stale.yml` | Issues after 60+14 days (beginner/program issues exempt). PRs only if labelled `waiting on author` |
| duplicates | `magnet-duplicates.yml` | Comments with up to 3 similar open or recently closed issues. Never closes |
| pr-labels | `magnet-pr-labels.yml` | `type:` from the title, `area:` from path globs, `size:`, `first-time contributor` |
| pr-hygiene | `magnet-pr-hygiene.yml` | Asks for `Closes #` once; warns when the linked issue belongs to someone else |
| issue-level | `magnet-issue-level.yml` | The Task form's Difficulty becomes a `level:` label (beginner also gets `good first issue`) |
| shoutout | `magnet-shoutout.yml` | 1st of the month: an issue listing last month's contributors, first-timers marked, with a ready-to-post text |
| program | `magnet-program-<name>.yml` | Program labels and points for GSSoC, SWoC, WOCS, etc. Opt-in per PR via a template checkbox |
## Run it
1. **Check what's there.** Read `.github/workflows/`. If a workflow already does a job (another claim bot, `actions/first-interaction`, `actions/labeler`, `actions/stale`), keep theirs or replace it with the user's OK. Two claim bots answering the same comment is worse than none.
2. **Install:**
```bash
node <this skill>/scripts/install.mjs --list # what's available
node <this skill>/scripts/install.mjs --target <repo> # the core set (all but shoutout and program)
node <this skill>/scripts/install.mjs --target <repo> --only claim,unassign-idle,welcome
node <this skill>/scripts/install.mjs --target <repo> --program gssoc --program-name "GirlScript Summer of Code 2027" \
--program-url https://gssoc.girlscript.org --end 2027-08-15 --points 10,25,45
```
It never overwrites existing files without `--force`.
3. **Tune the `env:` blocks** to the repo and the maintainer's capacity:
- Label names must match the repo's labels (`level:beginner` vs `level: beginner`, `type:bug` vs `type: bug`). Check `gh label list`.
- `MAX_OPEN` in claim: 5 suits most repos; 2–3 during a big program; maintainers are always exempt.
- `DAYS_LIMIT`: 7 is the norm. Larger issues can carry a `pinned` or `in progress` label to be exempt.
- `AREAS` in pr-labels: path globs for the repo's real layout.
- `REVIEW_TIME` in welcome: only what the maintainer can keep.
4. **Labels the bots use** must exist (`waiting on author`, `possible duplicate`, `first-time contributor`, `size: *`, `shoutout`). `magnet-setup`'s label script creates them.
5. **Commit on a branch and open a PR.** Workflows triggered by issues, comments and `pull_request_target` run from the default branch, so nothing happens until it's merged. After merging, test: open an issue from another account (or ask a friend), comment "can I work on this?", and check the Actions tab.
Details, permissions, security notes and the lesson behind each bot: [references/bots.md](references/bots.md).
## Don't
- Don't add `actions/checkout` to any `pull_request_target` workflow. They run with write permissions; checking out fork code there is how repos get compromised.
- Don't splice event text into scripts with `${{ github.event... }}`. Read it from `context.payload` inside the script, as these files do.
- Don't make the program status check a required check. It's a reminder for maintainers, and a required check blocks merges when a program's labels are wrong.
- Don't gate PRs on starring the repo.