{"id":47206357,"url":"https://github.com/github-community-projects/stale-repos","last_synced_at":"2026-03-27T19:01:01.114Z","repository":{"id":170658503,"uuid":"642585551","full_name":"github-community-projects/stale-repos","owner":"github-community-projects","description":"Find stale repositories in a GitHub organization.","archived":false,"fork":false,"pushed_at":"2026-03-26T20:25:12.000Z","size":994,"stargazers_count":195,"open_issues_count":2,"forks_count":39,"subscribers_count":133,"default_branch":"main","last_synced_at":"2026-03-26T23:15:48.153Z","etag":null,"topics":["actions","archive","github-action","hacktoberfest","ospo","python","stale"],"latest_commit_sha":null,"homepage":"https://github.blog/2023-06-05-announcing-the-stale-repos-action/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/github-community-projects.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":"SUPPORT.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-05-18T22:59:37.000Z","updated_at":"2026-03-26T01:10:07.000Z","dependencies_parsed_at":"2025-12-02T23:02:39.625Z","dependency_job_id":null,"html_url":"https://github.com/github-community-projects/stale-repos","commit_stats":{"total_commits":117,"total_committers":8,"mean_commits":14.625,"dds":0.2991452991452992,"last_synced_commit":"2b6cb6e104f4be7f8c2dd99f3d58ac4f18c7d43b"},"previous_names":["github/stale-repos","github-community-projects/stale-repos"],"tags_count":69,"template":false,"template_full_name":null,"purl":"pkg:github/github-community-projects/stale-repos","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github-community-projects%2Fstale-repos","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github-community-projects%2Fstale-repos/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github-community-projects%2Fstale-repos/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github-community-projects%2Fstale-repos/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/github-community-projects","download_url":"https://codeload.github.com/github-community-projects/stale-repos/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/github-community-projects%2Fstale-repos/sbom","scorecard":{"id":328813,"data":{"date":"2025-08-18T01:09:44Z","repo":{"name":"github.com/github/stale-repos","commit":"3eb622574e8badf035ee5316ad35764ae8b9ece0"},"scorecard":{"version":"v5.2.1","commit":"ab2f6e92482462fe66246d9e32f642855a691dc1"},"score":7.3,"checks":[{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#packaging"}},{"name":"Dependency-Update-Tool","score":10,"reason":"update tool detected","details":["Info: detected update tool: Dependabot: .github/dependabot.yml:1"],"documentation":{"short":"Determines if the project uses a dependency update tool.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#dependency-update-tool"}},{"name":"Maintained","score":10,"reason":"30 commit(s) and 1 issue activity found in the last 90 days -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":3,"reason":"dependency not pinned by hash detected -- score normalized to 3","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/docker-image.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/docker-image.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/linter.yaml:21: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/linter.yaml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/major-version-updater.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/major-version-updater.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/python-package.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/python-package.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/python-package.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/scorecard.yml:28: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/scorecard.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/scorecard.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/scorecard.yml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/stale.yaml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/stale.yaml/main?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/use-action.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/use-action.yml/main?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/use-action.yml:24: update your workflow using https://app.stepsecurity.io/secureworkflow/github/stale-repos/use-action.yml/main?enable=pin","Warn: pipCommand not pinned by hash: Dockerfile:16-19","Warn: pipCommand not pinned by hash: .github/workflows/linter.yaml:28","Warn: pipCommand not pinned by hash: .github/workflows/linter.yaml:29","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:29","Warn: pipCommand not pinned by hash: .github/workflows/python-package.yml:30","Info:   1 out of  10 GitHub-owned GitHubAction dependencies pinned","Info:   3 out of   4 third-party GitHubAction dependencies pinned","Info:   0 out of   5 pipCommand dependencies pinned","Info:   1 out of   1 containerImage dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#pinned-dependencies"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Info: jobLevel 'contents' permission set to 'read': .github/workflows/auto-labeler.yml:12","Info: jobLevel 'contents' permission set to 'read': .github/workflows/linter.yaml:16","Info: jobLevel 'packages' permission set to 'read': .github/workflows/linter.yaml:17","Warn: jobLevel 'statuses' permission set to 'write': .github/workflows/linter.yaml:18","Info: jobLevel 'contents' permission set to 'read': .github/workflows/pr-title.yml:12","Info: jobLevel 'pull-requests' permission set to 'read': .github/workflows/pr-title.yml:13","Warn: jobLevel 'statuses' permission set to 'write': .github/workflows/pr-title.yml:14","Warn: jobLevel 'contents' permission set to 'write': .github/workflows/release.yml:13","Info: jobLevel 'pull-requests' permission set to 'read': .github/workflows/release.yml:14","Info: jobLevel 'contents' permission set to 'read': .github/workflows/release.yml:24","Warn: jobLevel 'packages' permission set to 'write': .github/workflows/release.yml:25","Info: jobLevel 'contents' permission set to 'read': .github/workflows/release.yml:41","Info: jobLevel 'contents' permission set to 'read': .github/workflows/use-action.yml:17","Info: jobLevel 'packages' permission set to 'read': .github/workflows/use-action.yml:19","Info: topLevel 'contents' permission set to 'read': .github/workflows/auto-labeler.yml:8","Info: topLevel 'contents' permission set to 'read': .github/workflows/docker-image.yml:11","Info: topLevel 'contents' permission set to 'read': .github/workflows/linter.yaml:9","Warn: topLevel 'contents' permission set to 'write': .github/workflows/major-version-updater.yml:13","Info: topLevel 'contents' permission set to 'read': .github/workflows/pr-title.yml:8","Info: topLevel 'contents' permission set to 'read': .github/workflows/python-package.yml:13","Info: topLevel 'contents' permission set to 'read': .github/workflows/release.yml:9","Info: topLevel permissions set to 'read-all': .github/workflows/scorecard.yml:16","Info: topLevel 'pull-requests' permission set to 'read': .github/workflows/stale.yaml:8","Info: topLevel 'contents' permission set to 'read': .github/workflows/use-action.yml:11"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#token-permissions"}},{"name":"Code-Review","score":-1,"reason":"Found no human activity in the last 23 changesets","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#dangerous-workflow"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#license"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#cii-best-practices"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#vulnerabilities"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#signed-releases"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#fuzzing"}},{"name":"Security-Policy","score":10,"reason":"security policy file detected","details":["Info: security policy file detected: github.com/github/.github/SECURITY.md:1","Info: Found linked content: github.com/github/.github/SECURITY.md:1","Info: Found disclosure, vulnerability, and/or timelines in security policy: github.com/github/.github/SECURITY.md:1","Info: Found text in security policy: github.com/github/.github/SECURITY.md:1"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#security-policy"}},{"name":"SAST","score":10,"reason":"SAST tool is run on all commits","details":["Info: all commits (30) are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#sast"}},{"name":"Contributors","score":10,"reason":"project has 16 contributing companies or organizations","details":["Info: found contributions from: FigureTechnologies, InnerSourceCommons, alamocoders, alltheavo, argoproj, compeople, devsanantonio, doximity, figuretechnologies, github, lostechies, meridth, onwardllc, ossf, privateerproj, super-linter"],"documentation":{"short":"Determines if the project has a set of contributors from multiple organizations (e.g., companies).","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#contributors"}},{"name":"CI-Tests","score":10,"reason":"23 out of 23 merged PRs checked by a CI test -- score normalized to 10","details":null,"documentation":{"short":"Determines if the project runs tests before pull requests are merged.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#ci-tests"}},{"name":"Branch-Protection","score":4,"reason":"branch protection is not maximal on development and all release branches","details":["Info: 'allow deletion' disabled on branch 'main'","Info: 'force pushes' disabled on branch 'main'","Warn: 'branch protection settings apply to administrators' is disabled on branch 'main'","Warn: 'stale review dismissal' is disabled on branch 'main'","Warn: required approving review count is 1 on branch 'main'","Info: codeowner review is required on branch 'main'","Warn: 'last push approval' is disabled on branch 'main'","Warn: 'up-to-date branches' is disabled on branch 'main'","Info: status check found to merge onto on branch 'main'","Info: PRs are required in order to make changes on branch 'main'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/ab2f6e92482462fe66246d9e32f642855a691dc1/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-18T03:06:42.198Z","repository_id":170658503,"created_at":"2025-08-18T03:06:42.198Z","updated_at":"2025-08-18T03:06:42.198Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31055230,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-27T16:55:14.406Z","status":"ssl_error","status_checked_at":"2026-03-27T16:55:07.885Z","response_time":164,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["actions","archive","github-action","hacktoberfest","ospo","python","stale"],"created_at":"2026-03-13T14:00:40.690Z","updated_at":"2026-03-27T19:01:01.106Z","avatar_url":"https://github.com/github-community-projects.png","language":"Python","readme":"# Stale Repos Action\n\n\u003e [!IMPORTANT]\n\u003e This repository has moved from `github/stale-repos` to `github-community-projects/stale-repos`.\n\u003e Please update your git remote:\n\u003e\n\u003e ```shell\n\u003e git remote set-url origin git@github.com:github-community-projects/stale-repos.git\n\u003e ```\n\u003e\n\u003e Note: replace `origin` with the name of your remote if it's different.\n\n[![Lint Code Base](https://github.com/github-community-projects/stale-repos/actions/workflows/linter.yaml/badge.svg)](https://github.com/github-community-projects/stale-repos/actions/workflows/linter.yaml)\n[![CodeQL](https://github.com/github-community-projects/stale-repos/actions/workflows/github-code-scanning/codeql/badge.svg)](https://github.com/github-community-projects/stale-repos/actions/workflows/github-code-scanning/codeql)\n[![Docker Image CI](https://github.com/github-community-projects/stale-repos/actions/workflows/docker-image.yml/badge.svg)](https://github.com/github-community-projects/stale-repos/actions/workflows/docker-image.yml)\n[![Python CI](https://github.com/github-community-projects/stale-repos/actions/workflows/python-package.yml/badge.svg)](https://github.com/github-community-projects/stale-repos/actions/workflows/python-package.yml)\n[![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/github-community-projects/stale-repos/badge)](https://scorecard.dev/viewer/?uri=github.com/github-community-projects/stale-repos)\n\n(Used by the `github` organization!)\n\nThis project identifies and reports repositories with no activity for configurable amount of time, in order to surface inactive repos to be considered for archival.\nThe current approach assumes that the repos that you want to evaluate are available in a single GitHub organization.\nFor the purpose of this action, a repository is considered inactive if it has not had a `push` in a configurable amount of days (can also be configured to determine activity based on default branch. See `ACTIVITY_METHOD` for more details.).\n\nThis action was developed by GitHub so that we can keep our open source projects well maintained, and it was made open source in the hopes that it would help you too!\nWe are actively using and are archiving things in batches since there are many repositories on our report.\nTo find out more about how GitHub manages its open source, check out the [github-ospo repository](https://github.com/github/github-ospo).\n\nIf you are looking to identify stale pull requests and issues, check out [actions/stale](https://github.com/actions/stale)\n\n## Support\n\nIf you need support using this project or have questions about it, please [open up an issue in this repository](https://github.com/github-community-projects/stale-repos/issues).\nRequests made directly to GitHub staff or support team will be redirected here to open an issue.\nGitHub SLA's and support/services contracts do not apply to this repository.\n\n### OSPO GitHub Actions as a Whole\n\nAll feedback regarding our GitHub Actions, as a whole, should be communicated through [issues on our github-ospo repository](https://github.com/github/github-ospo/issues/new).\n\n## Use as a GitHub Action\n\n1. Create a repository to host this GitHub Action or select an existing repository.\n1. Create the env values from the sample workflow below (`GH_TOKEN`, `ORGANIZATION`, `EXEMPT_TOPICS`) with your information as plain text or repository secrets. More info on [creating secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets).\n   Note: Your GitHub token will need to have read access to all the repositories in the organization that you want evaluated\n1. Copy the below example workflow to your repository and put it in the `.github/workflows/` directory with the file extension `.yml` (ie. `.github/workflows/stale_repos.yml`)\n\n### Configuration\n\nBelow are the allowed configuration options:\n\n#### Authentication\n\nThis action can be configured to authenticate with GitHub App Installation or Personal Access Token (PAT). If all configuration options are provided, the GitHub App Installation configuration has precedence. You can choose one of the following methods to authenticate:\n\n##### GitHub App Installation\n\n| field                        | required | default | description                                                                                                                                                                                             |\n| ---------------------------- | -------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `GH_APP_ID`                  | True     | `\"\"`    | GitHub Application ID. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details.              |\n| `GH_APP_INSTALLATION_ID`     | True     | `\"\"`    | GitHub Application Installation ID. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details. |\n| `GH_APP_PRIVATE_KEY`         | True     | `\"\"`    | GitHub Application Private Key. See [documentation](https://docs.github.com/en/apps/creating-github-apps/authenticating-with-a-github-app/about-authentication-with-a-github-app) for more details.     |\n| `GITHUB_APP_ENTERPRISE_ONLY` | False    | `false` | Set this input to `true` if your app is created in GHE and communicates with GHE.                                                                                                                       |\n\n##### Personal Access Token (PAT)\n\n| field      | required | default | description                                                                                                           |\n| ---------- | -------- | ------- | --------------------------------------------------------------------------------------------------------------------- |\n| `GH_TOKEN` | True     | `\"\"`    | The GitHub Token used to scan the repository. Must have read access to all repository you are interested in scanning. |\n\n#### Other Configuration Options\n\n| field                      | required | default    | description                                                                                                                                                                                                                                                             |\n| -------------------------- | -------- | ---------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| `ACTIVITY_METHOD`          | false    | `\"pushed\"` | How to get the last active date of the repository. Defaults to `pushed`, which is the last time any branch had a push. Can also be set to `default_branch_updated` to instead measure from the latest commit on the default branch (good for filtering out dependabot ) |\n| `GH_ENTERPRISE_URL`        | false    | `\"\"`       | URL of GitHub Enterprise instance to use for auth instead of github.com                                                                                                                                                                                                 |\n| `INACTIVE_DAYS`            | true     |            | The number of days used to determine if repository is stale, based on `push` events                                                                                                                                                                                     |\n| `EXEMPT_REPOS`             | false    |            | Comma separated list of repositories to exempt from being flagged as stale. Supports Unix shell-style wildcards. ie. `EXEMPT_REPOS = \"stale-repos,test-repo,conf-*\"`                                                                                                    |\n| `EXEMPT_TOPICS`            | false    |            | Comma separated list of topics to exempt from being flagged as stale                                                                                                                                                                                                    |\n| `ORGANIZATION`             | false    |            | The organization to scan for stale repositories. If no organization is provided, this tool will search through repositories owned by the GH_TOKEN owner                                                                                                                 |\n| `ADDITIONAL_METRICS`       | false    |            | Configure additional metrics like days since last release or days since last pull request. This allows for more detailed reporting on repository activity. To include both metrics, set `ADDITIONAL_METRICS: \"release,pr\"`                                              |\n| `SKIP_EMPTY_REPORTS`       | false    | `true`     | Skips report creation when no stale repositories are identified. Setting this input to `false` means reports are always created, even when they contain no results.                                                                                                     |\n| `WORKFLOW_SUMMARY_ENABLED` | false    | `false`    | When set to `true`, automatically adds the stale repository report to the GitHub Actions workflow summary. This eliminates the need to manually add a step to display the Markdown content in the workflow summary.                                                     |\n\n### Example workflow\n\n```yaml\nname: stale repo identifier\n\non:\n  workflow_dispatch:\n  schedule:\n    - cron: \"3 2 1 * *\"\n\npermissions:\n  contents: read\n\njobs:\n  build:\n    name: stale repo identifier\n    runs-on: ubuntu-latest\n\n    permissions:\n      contents: read\n      issues: write\n\n    steps:\n      - uses: actions/checkout@v6\n        with:\n          persist-credentials: false\n\n      - name: Run stale_repos tool\n        uses: github-community-projects/stale-repos@v9\n        env:\n          GH_TOKEN: ${{ secrets.GH_TOKEN }}\n          ORGANIZATION: ${{ secrets.ORGANIZATION }}\n          EXEMPT_TOPICS: \"keep,template\"\n          INACTIVE_DAYS: 365\n          ACTIVITY_METHOD: \"pushed\"\n          ADDITIONAL_METRICS: \"release,pr\"\n\n      # This next step updates an existing issue. If you want a new issue every time, remove this step and remove the `issue-number: ${{ env.issue_number }}` line below.\n      - name: Check for the stale report issue\n        run: |\n          ISSUE_NUMBER=$(gh search issues \"Stale-repository-report\" --repo $REPO_WITH_OWNER --state open --match title --json number --jq \".[0].number\")\n          echo \"issue_number=$ISSUE_NUMBER\" \u003e\u003e \"$GITHUB_ENV\"\n        env:\n          GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}\n          REPO_WITH_OWNER: ${{ github.repository }}\n\n      - name: Create issue\n        uses: peter-evans/create-issue-from-file@v6\n        with:\n          issue-number: ${{ env.issue_number }}\n          title: Stale-repository-report\n          content-filepath: ./stale_repos.md\n          assignees: \u003cYOUR_GITHUB_HANDLE_HERE\u003e\n          token: ${{ secrets.GITHUB_TOKEN }}\n```\n\n### Using Workflow Summary\n\nYou can automatically include the stale repository report in your GitHub Actions workflow summary by setting `WORKFLOW_SUMMARY_ENABLED: true`. This eliminates the need for additional steps to display the results.\n\n```yaml\nname: stale repo identifier\n\non:\n  workflow_dispatch:\n  schedule:\n    - cron: \"3 2 1 * *\"\n\npermissions:\n  contents: read\n\njobs:\n  build:\n    name: stale repo identifier\n    runs-on: ubuntu-latest\n\n    steps:\n      - name: Run stale_repos tool\n        uses: github-community-projects/stale-repos@v9\n        env:\n          GH_TOKEN: ${{ secrets.GH_TOKEN }}\n          ORGANIZATION: ${{ secrets.ORGANIZATION }}\n          EXEMPT_TOPICS: \"keep,template\"\n          INACTIVE_DAYS: 365\n          ADDITIONAL_METRICS: \"release,pr\"\n          WORKFLOW_SUMMARY_ENABLED: true\n```\n\nWhen `WORKFLOW_SUMMARY_ENABLED` is set to `true`, the stale repository report will be automatically added to the GitHub Actions workflow summary, making it easy to see the results directly in the workflow run page.\n\n### Example stale_repos.md output\n\n```markdown\n# Inactive Repositories\n\nThe following repos have not had a push event for more than 3 days:\n\n| Repository URL                    | Days Inactive | Last Push Date | Visibility | Days Since Last Release | Days Since Last PR |\n| --------------------------------- | ------------: | -------------: | ---------: | ----------------------: | -----------------: |\n| https://github.com/github/.github |             5 |      2020-1-30 |    private |                      10 |                  7 |\n```\n\n### Using JSON instead of Markdown\n\nThe action outputs inactive repos in JSON format for further actions as seen below or use the JSON contents from the file: `stale_repos.json`.\n\nExample usage:\n\n```yaml\nname: stale repo identifier\n\non:\n  workflow_dispatch:\n  schedule:\n    - cron: \"3 2 1 * *\"\n\npermissions:\n  contents: read\n\njobs:\n  build:\n    name: stale repo identifier\n    runs-on: ubuntu-latest\n\n    steps:\n      - name: Run stale_repos tool\n        id: stale-repos\n        uses: github-community-projects/stale-repos@v9\n        env:\n          GH_TOKEN: ${{ secrets.GH_TOKEN }}\n          ORGANIZATION: ${{ secrets.ORGANIZATION }}\n          EXEMPT_TOPICS: \"keep,template\"\n          INACTIVE_DAYS: 365\n          ADDITIONAL_METRICS: \"release,pr\"\n\n      - name: Print output of stale_repos tool\n        run: echo \"${{ steps.stale-repos.outputs.inactiveRepos }}\"\n      - uses: actions/github-script@v8\n        with:\n          script: |\n            const repos = ${{ steps.stale-repos.outputs.inactiveRepos }}\n            for (const repo of repos) {\n              console.log(repo);\n              const issue = await github.rest.issues.create({\n                owner: \u003cORG_OWNER\u003e,\n                repo: \u003cREPOSITORY\u003e,\n                title: 'Stale repo' + repo.url,\n                body: 'This repo is stale. Please contact the owner to make it active again.',\n              });\n              console.log(issue);\n            }\n          github-token: ${{ secrets.GH_TOKEN }}\n```\n\n### Running against multiple organizations?\n\nYou can utilize the GitHub Actions Matrix Strategy as shown below to run against multiple organizations. Note that this workflow example uses a manual trigger instead of a cron based trigger. Either works, this is just another option to consider.\n\n```yaml\non:\n  - workflow_dispatch\n\nname: Run the report\n\npermissions:\n  contents: read\n\njobs:\n  report:\n    name: run report\n    runs-on: ubuntu-latest\n    strategy:\n      matrix:\n        org: [org1, org2]\n    steps:\n      - name: \"run stale-repos\"\n        uses: github-community-projects/stale-repos@v9\n        env:\n          GH_TOKEN: ${{ secrets.GH_TOKEN }}\n          ORGANIZATION: ${{ matrix.org }}\n          INACTIVE_DAYS: 365\n          ADDITIONAL_METRICS: \"release,pr\"\n```\n\n### Authenticating with a GitHub App and Installation\n\nYou can authenticate as a GitHub App Installation by providing additional environment variables. If `GH_TOKEN` is set alongside these GitHub App Installation variables, the `GH_TOKEN` will be ignored and not used.\n\n```yaml\non:\n  - workflow_dispatch\n\nname: Run the report\n\npermissions:\n  contents: read\n\njobs:\n  build:\n    name: stale repo identifier\n    runs-on: ubuntu-latest\n\n    steps:\n      - uses: actions/checkout@v6\n        with:\n          persist-credentials: false\n\n      - name: Run stale_repos tool\n        uses: github-community-projects/stale-repos@v9\n        env:\n          GH_APP_ID: ${{ secrets.GH_APP_ID }}\n          GH_APP_INSTALLATION_ID: ${{ secrets.GH_APP_INSTALLATION_ID }}\n          GH_APP_PRIVATE_KEY: ${{ secrets.GH_APP_PRIVATE_KEY }}\n          #GITHUB_APP_ENTERPRISE_ONLY: true --\u003e Set this if the gh app was created in GHE and the endpoint is also a GHE instance\n          ORGANIZATION: ${{ secrets.ORGANIZATION }}\n          EXEMPT_TOPICS: \"keep,template\"\n          INACTIVE_DAYS: 365\n          ACTIVITY_METHOD: \"pushed\"\n          ADDITIONAL_METRICS: \"release,pr\"\n```\n\n## Local usage without Docker\n\n1. Have Python v3.11 or greater installed\n1. [Install uv](https://docs.astral.sh/uv/getting-started/installation/)\n1. Copy `.env-example` to `.env`\n1. Fill out the `.env` file with a _token_ from a user that has access to the organization to scan (listed below). Tokens should have admin:org or read:org access.\n1. Fill out the `.env` file with the desired _inactive_days_ value. This should be a whole positive number representing the amount of inactivity that you want for flagging stale repos.\n1. (Optional) Fill out the `.env` file with the [repository topics](https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/classifying-your-repository-with-topics) _exempt_topics_ that you want to filter out from the stale repos report. This should be a comma separated list of topics.\n1. (Optional) Fill out the `.env` file with the exact _organization_ that you want to search in\n1. (Optional) Fill out the `.env` file with the exact _URL_ of the GitHub Enterprise that you want to search in. Keep empty if you want to search in the public `github.com`.\n1. `uv sync`\n1. Run `uv run python3 ./stale_repos.py`, which will output a list of repositories and the length of their inactivity\n\n## Local testing without Docker\n\n1. Have Python v3.11 or greater installed\n1. [Install uv](https://docs.astral.sh/uv/getting-started/installation/)\n1. `uv sync`\n1. `make lint`\n1. `make test`\n\n## License\n\n[MIT](LICENSE)\n\n## More OSPO Tools\n\nLooking for more resources for your open source program office (OSPO)? Check out the [`github-ospo`](https://github.com/github/github-ospo) repository for a variety of tools designed to support your needs.\n","funding_links":[],"categories":["Python"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgithub-community-projects%2Fstale-repos","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgithub-community-projects%2Fstale-repos","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgithub-community-projects%2Fstale-repos/lists"}