Loading page...Загружаем страницу...正在加载页面...
AtlasRepo

How to stop pull request spam on an open source repo

说明与用途

通过实施分支保护、必需审查、CODEOWNERS 和贡献者渠道,减少垃圾拉取请求,同时保持仓库对真实贡献者开放。

问题

Open source repositories often receive spam pull requests that consume maintainers’ time and clutter the merge queue.

结果

Implementing branch protection, required reviews, CODEOWNERS, and a contributor funnel significantly reduces spam pull requests while keeping the repository open to genuine contributors.

工作流

  • 1. Protect the main branch (e.g., main or master).
  • 2. Require passing CI checks and at least one approving review before merge.
  • 3. Add CODEOWNERS for sensitive files to auto‑assign reviewers.
  • 4. Create issue and pull‑request templates that ask for motivation, reproduction steps, and screenshots.
  • 5. For first‑time contributors, require opening an issue or discussion before a pull request.
  • 6. Close spam pull requests quickly with a brief explanation and link to CONTRIBUTING.md.
  • 7. Restrict write access to a minimal set of trusted maintainers.
  • 8. If abuse persists, consider disabling pull requests for strangers.

证据

Lock the merge path, gate first‑time contributors, and route strangers to issues or discussions first.

来源

Require passing checks and at least one approving review before merge.

来源

Add CODEOWNERS for the files that attract drive‑by changes.

来源

  • 记录日期: 2026-09-19T06:45:40.089Z