{"id":23613701,"url":"https://github.com/freckle/commenter-action","last_synced_at":"2025-11-06T09:30:34.564Z","repository":{"id":37790476,"uuid":"379355013","full_name":"freckle/commenter-action","owner":"freckle","description":"Action to comment on PRs with changed-paths-specific content","archived":false,"fork":false,"pushed_at":"2024-04-18T00:13:41.000Z","size":1427,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":13,"default_branch":"main","last_synced_at":"2024-04-18T06:52:40.514Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","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/freckle.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-06-22T17:47:38.000Z","updated_at":"2024-04-23T14:10:09.370Z","dependencies_parsed_at":"2024-01-03T01:27:31.164Z","dependency_job_id":"11f476d3-60f5-4937-a688-59033558a7b2","html_url":"https://github.com/freckle/commenter-action","commit_stats":{"total_commits":265,"total_committers":4,"mean_commits":66.25,"dds":0.04528301886792452,"last_synced_commit":"2e1f8a06106f745ad2b4be104192fe14ba2ecfc7"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fcommenter-action","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fcommenter-action/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fcommenter-action/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/freckle%2Fcommenter-action/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/freckle","download_url":"https://codeload.github.com/freckle/commenter-action/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239491352,"owners_count":19647811,"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","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":[],"created_at":"2024-12-27T17:18:49.594Z","updated_at":"2025-11-06T09:30:34.498Z","avatar_url":"https://github.com/freckle.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Pull Request Commenter\n\n## Configuration\n\n```yaml\n# .github/commenter.yml\n\nBackend:\n  where:\n    path:\n      matches: \"backend/**/*\"\n  body: |\n    :wave: You've changed Backend code, please:\n\n    - [ ] Do this\n    - [ ] And this\n    - [ ] And that\n\nFrontend:\n  where:\n    path:\n      matches: \"frontend/**/*\"\n  body: |\n    :wave: You've changed Frontend code, please:\n\n    - [ ] Do this\n    - [ ] And this\n    - [ ] And that\n```\n\nThe keys are ignored, and for your own organizational use. We will find the\n**first** stanza where the PR's changed files matches **any** of the given\n`paths` and add a comment with the given `body`.\n\n\u003c!-- action-docs-usage action=\"action.yml\" project=\"freckle/commenter-action\" version=\"v1\" --\u003e\n\n## Usage\n\n```yaml\n- uses: freckle/commenter-action@v1\n  with:\n    repo-token:\n    # The `GITHUB_TOKEN` secret\n    #\n    # Required: false\n    # Default: ${{ github.token }}\n\n    configuration-path:\n    # The path for the comment configurations\n    #\n    # Required: false\n    # Default: .github/commenter.yml\n\n    body-file-prefix:\n    # The path for finding body markdown files\n    #\n    # Required: false\n    # Default: .github/commenter/\n```\n\n\u003c!-- action-docs-usage action=\"action.yml\" project=\"freckle/commenter-action\" version=\"v1\" --\u003e\n\n\u003c!-- action-docs-inputs action=\"action.yml\" --\u003e\n\n## Inputs\n\n| name                 | description                                     | required | default                 |\n| -------------------- | ----------------------------------------------- | -------- | ----------------------- |\n| `repo-token`         | \u003cp\u003eThe \u003ccode\u003eGITHUB_TOKEN\u003c/code\u003e secret\u003c/p\u003e     | `false`  | `${{ github.token }}`   |\n| `configuration-path` | \u003cp\u003eThe path for the comment configurations\u003c/p\u003e  | `false`  | `.github/commenter.yml` |\n| `body-file-prefix`   | \u003cp\u003eThe path for finding body markdown files\u003c/p\u003e | `false`  | `.github/commenter/`    |\n\n\u003c!-- action-docs-inputs action=\"action.yml\" --\u003e\n\n## Permissions\n\nRunning this action requires the following permissions:\n\n```yaml\npermissions:\n  contents: read\n  pull-requests: write\n```\n\nThese are required to be explicitly set for repositories with [restricted\ndefault access][perms] for workflows or to allow a workflow run triggered by\nDependabot pull requests, which are run as if they are from a forked repository\nand use a read-only `GITHUB_TOKEN`.\n\n[perms]: https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token\n\n## Additional Options\n\nYou can also match based on specific file changes by supplying the\n`diff` `where`-clause configuration key.\n\nFor example, if you wanted to comment on any changes that contain the word\n\"unsafe\" you could supply a YAML configuration like the following\n\n```yaml\nUnsafeMentionedInCode:\n  where:\n    path:\n      matches: \"backend/**/*.hs\"\n    diff:\n      contains:\n        - unsafe\n  body: |\n    :wave: Hi, I see a mention of \"unsafe\" in Haskell code. If you removed it,\n    good going! If you added it, please consider finding a safer alternative!\n```\n\n`diff.adds` and `diff.removes` are also supported, to match on specifically\nadditions or removals of certain text.\n\nUse `where.author.any` to only comment on PRs that authored by specific users,\nand `where.labels.any` to only comment when specific labels are present. Keep\nin mind that all `where` conditions must be satisfied for a comment to be made:\n\n```yaml\nCommentOnAutomatedUpdate:\n  where:\n    path:\n      matches: \"*/**/yarn.lock\"\n    author:\n      any:\n        - dependabot[bot]\n    labels:\n      any:\n        - Frontend\n  body: |\n    This is an automated update to the frontend lockfile. Please verify the\n    integrity of the packages being updated.\n```\n\n## Reading the Comment Body from a File\n\nIf `body` is omitted, a file named `.github/commenter/{name}.md` is read from\nthe default branch for the comment contents. The `.github/commenter/` prefix can\nbe changed via `inputs.body-file-prefix`. The complete path, or just the name\npart, can be specified via the `body-file` and `body-file-name` attributes of\nthe configuration, respectively.\n\n## Acknowledgements\n\nThis action was highly inspired by (and began as a copy of)\n[`@actions/labeler`][labeler].\n\n[labeler]: https://github.com/actions/labeler\n\n---\n\n[LICENSE](./LICENSE) | [CHANGELOG](./CHANGELOG.md)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreckle%2Fcommenter-action","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffreckle%2Fcommenter-action","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffreckle%2Fcommenter-action/lists"}