diff options
| author | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-17 04:10:29 +0300 |
|---|---|---|
| committer | Ogulcan Celik <ogulcancelik@gmail.com> | 2026-05-17 04:19:50 +0300 |
| commit | 1586fc420942122c7b5948397becca9ddb602b15 (patch) | |
| tree | 7db45490dd1ef08a30c7a4f92f7f80a165441083 | |
| parent | db6f9afad27142248150096aa886f1057c1ebcd6 (diff) | |
chore: refine issue contributor intent flow
| -rw-r--r-- | .github/ISSUE_TEMPLATE/bug.yml | 61 | ||||
| -rw-r--r-- | .github/ISSUE_TEMPLATE/change.yml (renamed from .github/ISSUE_TEMPLATE/proposal.yml) | 25 | ||||
| -rw-r--r-- | .github/ISSUE_TEMPLATE/config.yml | 2 | ||||
| -rw-r--r-- | .github/workflows/label-intends-to-pr.yml | 9 | ||||
| -rw-r--r-- | CONTRIBUTING.md | 6 |
5 files changed, 85 insertions, 18 deletions
diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml new file mode 100644 index 00000000..408707b1 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug.yml @@ -0,0 +1,61 @@ +name: Bug report +description: Report something broken in herdr. +body: + - type: markdown + attributes: + value: | + **Before you start:** Read [CONTRIBUTING.md](https://github.com/ogulcancelik/herdr/blob/master/CONTRIBUTING.md). + + New PRs from unapproved contributors are auto-closed by default. Open an issue first and wait for maintainer approval. Issues that do not meet the quality bar in [CONTRIBUTING.md](https://github.com/ogulcancelik/herdr/blob/master/CONTRIBUTING.md) may be closed or left without a reply. + + Keep this short. If it does not fit on one screen, it is too long. Write in your own voice. + + - type: textarea + id: current-behavior + attributes: + label: Current behavior + description: What is happening now? + validations: + required: true + + - type: textarea + id: expected-behavior + attributes: + label: Expected behavior + description: What should happen instead? + validations: + required: true + + - type: textarea + id: reproduction + attributes: + label: Reproduction + description: What are the shortest steps that show the problem? + validations: + required: true + + - type: textarea + id: impact + attributes: + label: Impact + description: How does this affect you? + validations: + required: true + + - type: textarea + id: environment + attributes: + label: Environment + description: Herdr version, OS, terminal, shell, and any relevant config. + validations: + required: false + + - type: checkboxes + id: contribution-intent + attributes: + label: Contribution intent + options: + - label: I intend to open a PR for this issue. + required: false + - label: I understand this does not mean the issue is approved. + required: false diff --git a/.github/ISSUE_TEMPLATE/proposal.yml b/.github/ISSUE_TEMPLATE/change.yml index 01080b6e..a6cfbc48 100644 --- a/.github/ISSUE_TEMPLATE/proposal.yml +++ b/.github/ISSUE_TEMPLATE/change.yml @@ -1,11 +1,14 @@ -name: Change proposal -description: Propose a bug fix, feature, workflow change, or first-time contribution. -title: "[proposal]: " +name: Feature or behavior change +description: Propose a feature, behavior change, documentation change, or direction check. body: - type: markdown attributes: value: | - Before opening your first PR, describe the change here and wait for maintainer approval. + **Before you start:** Read [CONTRIBUTING.md](https://github.com/ogulcancelik/herdr/blob/master/CONTRIBUTING.md). + + New PRs from unapproved contributors are auto-closed by default. Open an issue first and wait for maintainer approval. Issues that do not meet the quality bar in [CONTRIBUTING.md](https://github.com/ogulcancelik/herdr/blob/master/CONTRIBUTING.md) may be closed or left without a reply. + + Keep this short. If it does not fit on one screen, it is too long. Write in your own voice. - type: textarea id: current-behavior @@ -16,18 +19,18 @@ body: required: true - type: textarea - id: proposed-change + id: requested-change attributes: - label: Proposed change + label: Requested change description: What do you want to change? validations: required: true - type: textarea - id: why-herdr + id: reason attributes: - label: Why this belongs in herdr - description: Explain why this fits herdr's direction. + label: Reason + description: Why does this belong in herdr? validations: required: true @@ -53,7 +56,7 @@ body: attributes: label: Contribution intent options: - - label: I intend to open a PR for this change. + - label: I intend to open a PR for this issue. required: false - - label: I understand this does not mean the change is approved. + - label: I understand this does not mean the issue is approved. required: false diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 64eb98dc..8005e322 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -1,2 +1,2 @@ -blank_issues_enabled: true +blank_issues_enabled: false contact_links: [] diff --git a/.github/workflows/label-intends-to-pr.yml b/.github/workflows/label-intends-to-pr.yml index 11136ec3..731f0f82 100644 --- a/.github/workflows/label-intends-to-pr.yml +++ b/.github/workflows/label-intends-to-pr.yml @@ -24,9 +24,10 @@ jobs: const body = context.payload.issue.body || ''; const issueNumber = context.payload.issue.number; const { owner, repo } = context.repo; - const checkedIntentPattern = /^\s*-\s*\[[xX]\]\s*I intend to open a PR for this change\.\s*$/m; - const uncheckedIntentPattern = /^\s*-\s*\[ \]\s*I intend to open a PR for this change\.\s*$/m; - const shouldAddLabel = checkedIntentPattern.test(body); + const checkedIntentPattern = /^\s*-\s*\[[xX]\]\s*I intend to open a PR for this (?:change|issue)\.\s*$/m; + const uncheckedIntentPattern = /^\s*-\s*\[ \]\s*I intend to open a PR for this (?:change|issue)\.\s*$/m; + const cliIntentPattern = /^\s*\/i-intend-to-pr\s*$/m; + const shouldAddLabel = checkedIntentPattern.test(body) || cliIntentPattern.test(body); const shouldRemoveLabel = uncheckedIntentPattern.test(body); const labels = context.payload.issue.labels.map((item) => typeof item === 'string' ? item : item.name, @@ -44,7 +45,7 @@ jobs: } if (!shouldAddLabel && !shouldRemoveLabel) { - console.log(`No contribution intent checkbox found for #${issueNumber}.`); + console.log(`No contribution intent signal found for #${issueNumber}.`); return; } diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0837c008..8b4d6d9d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -26,10 +26,12 @@ If you have a suggestion, disagreement, or contradiction with the current produc We use an approval gate for new contributors. -Before opening your first PR, open an issue describing what you want to change and why. Keep it short. Write in your own voice. If you intend to implement it yourself, check the contribution intent box in the issue form. The `intends-to-pr` label will be added automatically. A maintainer will comment `/approve` if the direction is approved. Once approved, you can open PRs. +Before opening your first PR, open an issue describing what you want to change and why. Keep it short. Write in your own voice. If you intend to implement it yourself, check the contribution intent box in the issue form, or include `/i-intend-to-pr` in the issue body when using the GitHub CLI or API. The `intends-to-pr` label will be added automatically. A maintainer will comment `/approve` if the direction is approved. Once approved, you can open PRs. This exists because AI makes it trivial to generate plausible-looking contributions that do not fit the app. +Agent note: if you are an AI agent preparing an issue or PR for this repository, check whether the human's GitHub username is listed in `.github/APPROVED_CONTRIBUTORS`. If they are not listed, warn them that opening a PR will be closed automatically and guide them to open an issue first. Keep the scope small, preserve herdr's product direction, run the documented checks, and make sure the human can explain the change. Do not open a PR before the issue is approved. + ## What to put in a first issue Your first issue should answer these questions clearly: @@ -44,7 +46,7 @@ If your proposal changes the visual language, interaction model, or overall prod If your issue does not make the direction clear, it will likely be closed. -If you plan to implement the change yourself, say that directly in the issue and check the contribution intent box. That adds the `intends-to-pr` label automatically, signals intent, and does not mean the change is approved. +If you plan to implement the change yourself, say that directly in the issue and check the contribution intent box. If you are using the GitHub CLI or API, include `/i-intend-to-pr` in the issue body instead. That adds the `intends-to-pr` label automatically, signals intent, and does not mean the change is approved. ## Documentation for unreleased changes |
