From c156315df4b4e6e7064cbf05b4cde0eb0fe14ea1 Mon Sep 17 00:00:00 2001 From: Brandon Corbett Date: Sat, 25 Jul 2026 19:53:15 -0400 Subject: [PATCH] chore: remove PR star-check workflow and star requirement --- .github/workflows/pr-star-check.yml | 75 ----------------------------- CONTRIBUTING.md | 15 ------ 2 files changed, 90 deletions(-) delete mode 100644 .github/workflows/pr-star-check.yml diff --git a/.github/workflows/pr-star-check.yml b/.github/workflows/pr-star-check.yml deleted file mode 100644 index 5848594..0000000 --- a/.github/workflows/pr-star-check.yml +++ /dev/null @@ -1,75 +0,0 @@ -name: PR Star Check - -on: - pull_request: - types: - - opened - - reopened - - synchronize - - ready_for_review - -permissions: - contents: read - -jobs: - require-star: - runs-on: ubuntu-latest - - steps: - - name: Check contributor has starred repository - env: - CONTRIBUTOR: ${{ github.event.pull_request.user.login }} - OWNER: ${{ github.repository_owner }} - REPO: ${{ github.event.repository.name }} - run: | - set -euo pipefail - - if [[ "$CONTRIBUTOR" == *"[bot]" ]]; then - echo "Bot pull request detected; skipping star requirement." - exit 0 - fi - - page=1 - found=0 - - while true; do - response="$(curl -fsSL \ - -H "Accept: application/vnd.github+json" \ - "https://api.github.com/users/${CONTRIBUTOR}/starred?per_page=100&page=${page}")" - - count="$(node -e ' - const fs = require("fs"); - const data = JSON.parse(fs.readFileSync(0, "utf8")); - console.log(Array.isArray(data) ? data.length : 0); - ' <<<"$response")" - - match="$(node -e ' - const fs = require("fs"); - const [owner, repo] = process.argv.slice(1); - const data = JSON.parse(fs.readFileSync(0, "utf8")); - const found = Array.isArray(data) && data.some((item) => - item?.owner?.login?.toLowerCase() === owner.toLowerCase() && - item?.name?.toLowerCase() === repo.toLowerCase(), - ); - console.log(found ? "1" : "0"); - ' "$OWNER" "$REPO" <<<"$response")" - - if [[ "$match" == "1" ]]; then - found=1 - break - fi - - if [[ "$count" -lt 100 ]]; then - break - fi - - page=$((page + 1)) - done - - if [[ "$found" == "1" ]]; then - echo "${CONTRIBUTOR} has starred ${OWNER}/${REPO}." - exit 0 - fi - - echo "::error title=Repository star required::Please star ${OWNER}/${REPO} before opening a pull request." - exit 1 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 9fe0e12..678e05f 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -171,21 +171,6 @@ feat: add configurable token expiration override - Include tests - Update docs - Pass CI -- Come from contributors who have starred the repository - -## Star Requirement - -We only accept pull requests from contributors who have starred this repository on GitHub. - -This requirement is enforced automatically for pull requests opened against the public GitHub repository. - -If you plan to open a pull request: - -1. Visit the repository page on GitHub -2. Click `Star` -3. Open your pull request after the star is visible on your account - -Pull requests that do not meet this requirement may be closed without review. ## Licensing