{"id":19450928,"url":"https://github.com/sourcery-ai/action","last_synced_at":"2025-09-25T09:05:49.776Z","repository":{"id":64101800,"uuid":"562860974","full_name":"sourcery-ai/action","owner":"sourcery-ai","description":"A GitHub Action for running Sourcery.","archived":false,"fork":false,"pushed_at":"2023-12-15T08:49:47.000Z","size":15,"stargazers_count":28,"open_issues_count":5,"forks_count":2,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-03T20:59:12.333Z","etag":null,"topics":["action","actions","ci","continuous-delivery","continuous-integration","github","github-actions"],"latest_commit_sha":null,"homepage":"","language":null,"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/sourcery-ai.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2022-11-07T12:14:49.000Z","updated_at":"2025-06-18T12:05:10.000Z","dependencies_parsed_at":"2023-12-15T09:51:38.126Z","dependency_job_id":null,"html_url":"https://github.com/sourcery-ai/action","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/sourcery-ai/action","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourcery-ai%2Faction","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourcery-ai%2Faction/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourcery-ai%2Faction/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourcery-ai%2Faction/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sourcery-ai","download_url":"https://codeload.github.com/sourcery-ai/action/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourcery-ai%2Faction/sbom","scorecard":{"id":839450,"data":{"date":"2025-08-11","repo":{"name":"github.com/sourcery-ai/action","commit":"6eaab6f77c4543d19a8662d035c3f3e4e5f8ed91"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":4.1,"checks":[{"name":"Code-Review","score":3,"reason":"Found 4/11 approved changesets -- score normalized to 3","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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/issue-automation.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/sourcery-ai/action/issue-automation.yml/main?enable=pin","Info:   0 out of   1 GitHub-owned GitHubAction 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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/issue-automation.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"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/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 6 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-23T20:05:29.092Z","repository_id":64101800,"created_at":"2025-08-23T20:05:29.092Z","updated_at":"2025-08-23T20:05:29.092Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276888885,"owners_count":25722730,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-25T02:00:09.612Z","response_time":80,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["action","actions","ci","continuous-delivery","continuous-integration","github","github-actions"],"created_at":"2024-11-10T16:39:37.192Z","updated_at":"2025-09-25T09:05:49.740Z","avatar_url":"https://github.com/sourcery-ai.png","language":null,"readme":"# Sourcery GitHub Action\n\n## Overview\n\nRun [Sourcery](https://sourcery.ai/) as a GitHub Action that you can easily add to your\nContinuous Integration.\n\nThis action performs the following operations:\n\n* Installs Sourcery on your worker machine\n* Logs in to Sourcery using your access token\n* Reviews your code\n\n\u003e **Note**: the Sourcery GitHub Action is FREE for open-source projects.\n\n\u003e **Note**: for private repositories, a \n\u003e [TEAM subscription](https://docs.sourcery.ai/Product/Plans/#team) is required.\n\u003e Check out our [pricing page](https://sourcery.ai/pricing/) to sign up.\n\n## Usage\n\n### Check your entire codebase\n\nTo run Sourcery over your entire codebase whenever a push is done to the `main` branch:\n\n```yaml\nname: Check codebase using Sourcery\n\non:\n  push:\n    branches: [main]\n\njobs:\n  review-with-sourcery:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions/checkout@v3\n\n      - uses: actions/setup-python@v4\n        with:\n          python-version: '3.10'\n\n      - uses: sourcery-ai/action@v1\n        with:\n          token: ${{ secrets.SOURCERY_TOKEN }}\n```\n\nWe recommend you store your Sourcery token as a\n[GitHub secret](https://docs.github.com/en/actions/security-guides/encrypted-secrets) on\nyour repository. In the example above, that secret was stored as `SOURCERY_TOKEN`.\n\nYou can retrieve your Sourcery token from your\n[dashboard](https://sourcery.ai/dashboard/profile).\n\n### Check your PR\n\nTo run Sourcery only on the changed code in a PR:\n\n```yaml\nname: Check PR using Sourcery\n\non: pull_request\n\njobs:\n  review-with-sourcery:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions/checkout@v3\n        with:\n          fetch-depth: 0\n\n      - uses: actions/setup-python@v4\n        with:\n          python-version: '3.10'\n\n      - uses: sourcery-ai/action@v1\n        with:\n          token: ${{ secrets.SOURCERY_TOKEN }}\n          diff_ref: ${{ github.event.pull_request.base.sha }}\n```\n\nNote here that we pass the `fetch-depth: 0` option to\n[`actions/checkout@v3`](https://github.com/actions/checkout). This is necessary because\nSourcery needs access to both the current branch and the main branch in order to compute\ndiffs.\n\n## Inputs\n\n### `token`\n\n\u003e **Type**: string\n\u003e\n\u003e **CLI equivalent**: `--token \u003ctoken\u003e`\n\nA Sourcery token. You can retrieve yours at the\n[Sourcery dashboard](https://sourcery.ai/dashboard/profile).\n\nWe recommend you to store your token as a\n[GitHub secret](https://docs.github.com/en/actions/security-guides/encrypted-secrets).\n\n### `target`\n\n\u003e **Type**: string\n\u003e\n\u003e **Default**: `.`\n\u003e\n\u003e **CLI equivalent**: `--target \u003ctarget\u003e`\n\nFile(s) or directory(ies) for Sourcery to review.\n\nThis defaults to `\".\"`, meaning that Sourcery will review your entire project.\n\nTo review only the directories `dir1/` and `dir2/` along with the files `file1.py` and\n`file2.py`, pass them as space-separated strings:\n\n```yaml\n- uses: sourcery-ai/action@v1\n  with:\n    token: ${{ secrets.SOURCERY_TOKEN }}\n    target: dir1 dir2 file1.py file2.py\n```\n\n### `version`\n\n\u003e **Type**: string\n\u003e\n\u003e **Default**: The latest Sourcery version available\n\u003e\n\u003e **CLI equivalent**: None\n\nThe Sourcery CLI version to use.\n\nThis defaults to the latest version available.\n\nTo choose a specific version (let's say `v1.5.0`):\n\n```yaml\n- uses: sourcery-ai/action@v1\n  with:\n    token: ${{ secrets.SOURCERY_TOKEN }}\n    version: 1.5.0\n```\n\nWe recommend you _not_ to this option unless strictly necessary. Pinning a Sourcery\nversion may leave you out from the awesome features we are working on - as well as\nbugfixes ;)\n\n### `verbose`\n\n\u003e **Type**: either `true` or `false`\n\u003e\n\u003e **Default**: `true`\n\u003e\n\u003e **CLI equivalent**: `--verbose`\n\nEnable or disable Sourcery's verbose output.\n\n### `check`\n\n\u003e **Type**: either `true` or `false`\n\u003e\n\u003e **Default**: `true`\n\u003e\n\u003e **CLI equivalent**: `--check`\n\nWhether Sourcery should return an error code or not if issues are found in the code.\n\nThis defaults to `true`, and hence the Sourcery CI step will fail in case Sourcery finds\nissues in your code. You can pass `false` to prevent that behavior.\n\n### `fix`\n\n\u003e **Type**: either `true` or `false`\n\u003e\n\u003e **Default**: `false`\n\u003e\n\u003e **CLI equivalent**: `--fix`\n\nWhether Sourcery should automatically fix and modify the reviewed files in-place or not.\n\n### `config`\n\n\u003e **Type**: string\n\u003e\n\u003e **Default**: None\n\u003e\n\u003e **CLI equivalent**: `--config \u003cconfig-path\u003e`\n\nPath to a valid Sourcery configuration file.\n\nBy default, this searches the current directory and its parents for a `.sourcery.yaml`\nfile.\n\nTo use a configuration file located elsewhere (for instance, at\n**`config_files/.my-team-rules.yaml`**):\n\n```yaml\n- uses: sourcery-ai/action@v1\n  with:\n    token: ${{ secrets.SOURCERY_TOKEN }}\n    config: config_files/.my-team-rules.yaml\n```\n\n### `diff_ref`\n\n\u003e **Type**: string\n\u003e\n\u003e **Default**: None\n\u003e\n\u003e **CLI equivalent**: `--diff=\"git diff \u003cdiff_ref\u003e\"`\n\nA reference to compute a `git diff`.\n\nThis is not used by default. In this case, Sourcery will run over the entire\n[`target`](#target) files.\n\nTo run Sourcery only on the changed lines in a PR, use:\n\n```yaml\n- uses: sourcery-ai/action@v1\n  with:\n    token: ${{ secrets.SOURCERY_TOKEN }}\n    diff_ref: ${{ github.event.pull_request.base.sha }}\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsourcery-ai%2Faction","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsourcery-ai%2Faction","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsourcery-ai%2Faction/lists"}