{"id":16391745,"url":"https://github.com/williamfzc/diffctx","last_synced_at":"2025-09-05T11:43:42.854Z","repository":{"id":153116641,"uuid":"627482282","full_name":"williamfzc/diffctx","owner":"williamfzc","description":"A GitHub action for automatically evaluating the logic level impacts of Pull Requests. Multi languages support.","archived":false,"fork":false,"pushed_at":"2023-08-14T13:02:39.000Z","size":75,"stargazers_count":36,"open_issues_count":2,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-08-31T02:41:22.031Z","etag":null,"topics":["codereview","github-actions","pullrequest"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/williamfzc.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2023-04-13T14:57:50.000Z","updated_at":"2025-08-30T16:25:12.000Z","dependencies_parsed_at":null,"dependency_job_id":"fc30f68b-eeb8-4698-b2da-e25541d99ae1","html_url":"https://github.com/williamfzc/diffctx","commit_stats":null,"previous_names":[],"tags_count":38,"template":false,"template_full_name":null,"purl":"pkg:github/williamfzc/diffctx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/williamfzc%2Fdiffctx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/williamfzc%2Fdiffctx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/williamfzc%2Fdiffctx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/williamfzc%2Fdiffctx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/williamfzc","download_url":"https://codeload.github.com/williamfzc/diffctx/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/williamfzc%2Fdiffctx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273753171,"owners_count":25161910,"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-05T02:00:09.113Z","response_time":402,"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":["codereview","github-actions","pullrequest"],"created_at":"2024-10-11T04:47:14.084Z","updated_at":"2025-09-05T11:43:42.821Z","avatar_url":"https://github.com/williamfzc.png","language":"Python","readme":"# diffctx = diff context\n\n[![Latest Release](https://img.shields.io/github/v/release/williamfzc/diffctx?include_prereleases)](https://github.com/williamfzc/diffctx/releases/latest)\n\nA GitHub action for automatically evaluating the logic level impacts of Pull Requests.\n\n## Showcase\n\nWith a simple setup in your GitHub Action:\n\n```yaml\n- name: diffctx\n  uses: williamfzc/diffctx@v0.3.13\n  with:\n    lang: \"golang\"\n```\n\nDiffctx will automatically analyse the diff (**and the context of diff**) every new PullRequests in your repo, and leave\ncomments for indicating which part you should care most:\n\n\u003cimg width=\"912\" alt=\"image\" src=\"https://github.com/williamfzc/srctx/assets/13421694/46de1eaa-efd2-496e-ba85-838e3da1063c\"\u003e\n\n\u003e https://github.com/williamfzc/srctx/pull/52\n\nBased on [LSIF](https://microsoft.github.io/language-server-protocol/overviews/lsif/overview/), diffctx will not only\nanalyse the lines contained by the diff, but also the full scope of your repo, and understand it well.\n\n## Usage\n\ndiffctx can be directly used with GitHub Action.\n\n### Add to GitHub Action\n\n```yaml\nname: Test PR\n\n# triggered by pull_request\non: [ push, pull_request ]\n\n# for creating comments\npermissions:\n  pull-requests: write\n\njobs:\n  build:\n    runs-on: ubuntu-latest\n    steps:\n      - uses: actions/checkout@v3\n        with:\n          # at least\n          fetch-depth: 2\n\n      # ...\n\n      - name: diffctx\n        uses: williamfzc/diffctx@v0.3.13\n        with:\n          # see the `Supported Langs` for details\n          lang: \"golang\"\n```\n\n### Done!\n\nYou can create a new PullRequest for test.\n\nOr test it with a push. You can find it in actions log.\n\n\u003cimg width=\"1046\" alt=\"image\" src=\"https://github.com/williamfzc/diffctx/assets/13421694/bd6370d5-c7d0-4530-949f-94a66770923a\"\u003e\n\n## Supported Languages\n\n### Overview\n\n| Language | Ready? | Keyword in yaml | Real-world Sample                                                                                                 |\n|----------|--------|-----------------|-------------------------------------------------------------------------------------------------------------------|\n| Golang   | ✅      | `golang`        | [ci.yml](https://github.com/williamfzc/srctx/blob/test_diffctx/.github/workflows/ci.yml)                          |\n| Java     | ✅      | `java`          | [main.yml](https://github.com/williamfzc/java-diffctx-sample/blob/main/.github/workflows/main.yml)                |\n| Kotlin   | ✅🚧    | `kotlin`        | [build.yml](https://github.com/williamfzc/kt-diffctx-sample/blob/main/.github/workflows/build.yml)                |\n| NodeJs   | ✅      | `node`          | [build.yml](https://github.com/williamfzc/node-diffctx-sample/blob/master/.github/workflows/grpc-tools-build.yml) |\n| Python   | ✅      | `python`        | [run-test.yml](https://github.com/williamfzc/py-diffctx-sample/blob/main/.github/workflows/run-tests.yml)         |\n\n### Want more langs?\n\nThanks to tree-sitter and LSIF, diffctx can support nearly all the popular languages.\n\nhttps://lsif.dev/\n\nAdding a new language support is not hard. PullRequests are always welcome!\n\n## How it works\n\n![](https://user-images.githubusercontent.com/13421694/236665125-4968558b-8601-43d0-9618-97e146f93749.svg)\n\n1. Scan the repo and understand it well\n2. Extract the sub graph influenced by the diff\n3. Generate a summary from sub graph\n4. Create a comment\n\n## Contribution\n\nIssues, PRs and suggestions are always welcome.\n\n- [diffctx](https://github.com/williamfzc/diffctx): for the whole workflow\n- [srctx](https://github.com/williamfzc/srctx): the core analyzer\n\n## Roadmap\n\n- [ ] More languages\n- [ ] Better comment format\n- [ ] Extract more meaningful columns (like function definition) from code\n- [ ] Display graph in comment also\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilliamfzc%2Fdiffctx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwilliamfzc%2Fdiffctx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwilliamfzc%2Fdiffctx/lists"}