diff --git a/.github/ISSUE_TEMPLATE/bug.yml b/.github/ISSUE_TEMPLATE/bug.yml index efdb38d190..b9c96cfc9e 100644 --- a/.github/ISSUE_TEMPLATE/bug.yml +++ b/.github/ISSUE_TEMPLATE/bug.yml @@ -22,6 +22,8 @@ body: required: true - label: This issue's title and/or description do not reference a single formula e.g. `brew install wget`. If they do, open an issue at https://github.com/Homebrew/homebrew-core/issues/new/choose instead. required: true + - label: I did not use AI/LLM to create this issue, or I disclosed the tool and model used; I will answer maintainer questions myself without AI/LLM. + required: true - type: textarea attributes: render: shell diff --git a/.github/ISSUE_TEMPLATE/feature.yml b/.github/ISSUE_TEMPLATE/feature.yml index d8a4b36fca..11dceb0210 100644 --- a/.github/ISSUE_TEMPLATE/feature.yml +++ b/.github/ISSUE_TEMPLATE/feature.yml @@ -12,6 +12,8 @@ body: options: - label: This issue's title and/or description do not reference a single formula e.g. `brew install wget`. If they do, open an issue at https://github.com/Homebrew/homebrew-core/issues/new/choose instead. required: true + - label: I did not use AI/LLM to create this issue, or I disclosed the tool and model used; I will answer maintainer questions myself without AI/LLM. + required: true - type: textarea attributes: label: Provide a detailed description of the proposed feature diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index c85e6752ad..b1fdccee50 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -14,8 +14,8 @@ ----- -- [ ] AI was used to generate or assist with generating this PR. +- [ ] I did not use AI/LLM to create this PR, or I disclosed the tool/model below and reviewed its output; I did not attribute commits to AI and will answer maintainer questions and review comments myself without AI/LLM. - + ----- diff --git a/.github/workflows/commit-style.yml b/.github/workflows/commit-style.yml new file mode 100644 index 0000000000..4b85e48b8b --- /dev/null +++ b/.github/workflows/commit-style.yml @@ -0,0 +1,21 @@ +name: Commit Style + +on: + pull_request: + branches: ["**"] + +permissions: {} + +jobs: + check-commit-format: + runs-on: ubuntu-slim + permissions: + contents: read + pull-requests: read + statuses: write + steps: + - name: Check commit format + uses: Homebrew/actions/check-commit-format@9af03b7ae3f9e2ae5c174f659d5c3909f7e7dbac # 2026.07.29.1 + with: + token: ${{ secrets.GITHUB_TOKEN }} + check_package_commit_format: false diff --git a/.github/workflows/reject-conventional-commits.yml b/.github/workflows/reject-conventional-commits.yml deleted file mode 100644 index 6dad994361..0000000000 --- a/.github/workflows/reject-conventional-commits.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Commit Style - -on: - pull_request: - branches: ["**"] - -permissions: {} - -jobs: - reject-conventional-commits: - runs-on: ubuntu-slim - permissions: - contents: read - steps: - - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 - with: - fetch-depth: 25 - persist-credentials: false - - - name: Check commit titles - env: - BASE_SHA: ${{ github.event.pull_request.base.sha }} - HEAD_SHA: ${{ github.event.pull_request.head.sha }} - shell: bash - run: | - set -euo pipefail - pattern='^(feat|fix|chore|refactor|perf|ci)(\([^)]*\))?!?:' - violations=() - while IFS= read -r title; do - if [[ "$title" =~ $pattern ]]; then - violations+=("$title") - fi - done < <(git log --format=%s "${BASE_SHA}..${HEAD_SHA}") - if (( ${#violations[@]} > 0 )); then - echo "Conventional commit prefixes are not allowed. Found:" - printf ' - %s\n' "${violations[@]}" - exit 1 - fi - echo "OK — no conventional commit prefixes found." diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 2a9477ef88..878d70aaa0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -28,7 +28,8 @@ We allow you to create issues and pull requests with AI/LLM with the following r * You must disclose in the initial issue or pull request that you used AI/LLM and what tool/model/etc. you used. * You must review all AI/LLM generated code, prose, etc. content before you ask anyone in Homebrew to review it for you. -* You must be able to address all pull request review comments, manually if the AI/LLM cannot do so for you. +* You must not attribute a commit to AI/LLM as an author, co-author, committer or signatory, including through an `Assisted-by`, `Co-developed-by` or similar commit trailer. +* You must answer all maintainer questions and pull request review comments yourself, without using AI/LLM. * Unless you are a maintainer, you may only have one AI-assisted/generated pull request open at a time. * If you reach the point where you feel unwilling or unable to do the above, please close your issue or pull request. diff --git a/docs/How-To-Open-a-Homebrew-Pull-Request.md b/docs/How-To-Open-a-Homebrew-Pull-Request.md index 94fd541474..a6ccd13d6c 100644 --- a/docs/How-To-Open-a-Homebrew-Pull-Request.md +++ b/docs/How-To-Open-a-Homebrew-Pull-Request.md @@ -1,5 +1,5 @@ --- -last_review_date: "2026-07-18" +last_review_date: "2026-07-26" --- # How to Open a Homebrew Pull Request @@ -151,7 +151,8 @@ We allow you to create issues and pull requests with AI/LLM with the following r * You must disclose in the initial issue or pull request that you used AI/LLM and what tool/model/etc. you used. * You must review all AI/LLM generated code, prose, etc. content before you ask anyone in Homebrew to review it for you. -* You must be able to address all pull request review comments, manually if the AI/LLM cannot do so for you. +* You must not attribute a commit to AI/LLM as an author, co-author, committer or signatory, including through an `Assisted-by`, `Co-developed-by` or similar commit trailer. +* You must answer all maintainer questions and pull request review comments yourself, without using AI/LLM. * If you reach the point where you feel unwilling or unable to do the above, please close your issue or pull request. ## Following up diff --git a/docs/Responsible-AI-Usage.md b/docs/Responsible-AI-Usage.md index 5c260fd33b..90adfa8863 100644 --- a/docs/Responsible-AI-Usage.md +++ b/docs/Responsible-AI-Usage.md @@ -1,5 +1,5 @@ --- -last_review_date: "2026-06-10" +last_review_date: "2026-07-26" --- # Responsible AI Usage @@ -15,12 +15,17 @@ These guidelines exist to make Homebrew better rather than shifting work and ris AI is not responsible for its output: you are responsible for the output of the AI tools you use. A pull request with your name on it is your work regardless of how much of it an AI wrote. +Do not identify an AI tool as an author, co-author, committer or signatory of a commit, including through an `Assisted-by`, `Co-developed-by` or similar commit trailer. +Disclose the tool's involvement in the pull request description instead. Verify AI output for correctness as you would that of an avatarless GitHub user with no previous contributions. Read it, run it, test it and make sure you understand it. Do not ask other humans to review your AI-generated code until you have reviewed it yourself. -This is already a requirement in our [Contributing guide](https://github.com/Homebrew/brew/blob/HEAD/CONTRIBUTING.md): you must review all AI/LLM-generated content before asking anyone in Homebrew to review it, and you must be able to address all review comments yourself even when the AI cannot. +This is already a requirement in our [Contributing guide](https://github.com/Homebrew/brew/blob/HEAD/CONTRIBUTING.md): you must review all AI/LLM-generated content before asking anyone in Homebrew to review it. + +Answer maintainer questions and pull request review comments yourself without using AI/LLM. +Reviewers need to engage directly with the person responsible for the contribution. As the [pull request template](https://github.com/Homebrew/brew/blob/HEAD/.github/PULL_REQUEST_TEMPLATE.md) sets out, disclose when AI was used to generate or assist with a pull request and explain how you verified the changes.