{"id":18664084,"url":"https://github.com/phansch/mend-rs","last_synced_at":"2025-11-06T08:30:34.822Z","repository":{"id":147634959,"uuid":"153338789","full_name":"phansch/mend-rs","owner":"phansch","description":"Clippy for your Pull Requests","archived":false,"fork":false,"pushed_at":"2019-09-03T11:25:13.000Z","size":82,"stargazers_count":1,"open_issues_count":10,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-12-27T17:16:20.733Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Rust","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/phansch.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":"2018-10-16T19:00:30.000Z","updated_at":"2019-09-03T15:32:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"6045d39b-0ca3-441e-979b-0c40d07bdb13","html_url":"https://github.com/phansch/mend-rs","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phansch%2Fmend-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phansch%2Fmend-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phansch%2Fmend-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/phansch%2Fmend-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/phansch","download_url":"https://codeload.github.com/phansch/mend-rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239488177,"owners_count":19647152,"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-11-07T08:21:34.859Z","updated_at":"2025-02-18T14:30:04.873Z","avatar_url":"https://github.com/phansch.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mend-rs\n\n[![Build Status](https://travis-ci.com/phansch/mend-rs.svg?branch=master)](https://travis-ci.com/phansch/mend-rs)\n\n## Development\n\nRun `bin/setup` to install all dependencies.\n\n## Dokku/Server stuff\n\n```shell\ndokku logs mend-rs -t\n```\n\nNeed to also set the following ENV variables on the server:\n\n* GH_CLIENT_ID\n* GH_CLIENT_SECRET\n* DATABASE_URL\n\nYou can find them at the bottom of https://github.com/settings/apps/mend-rs\n\n## User Workflow\n\n1. Users sign up with GitHub\n2. They see a repo selection screen\n3. They select a repo to register PR hook\n4. Done, they will see the comments in new PRs\n\nIt should only comment on changed or added lines\n\n## Technical Workflow\n\n1. [ ] Register PR hook\n1. [ ] On PR, we will receive the hook notification, and start a new docker container with nightly rust + clippy\n1. [ ] Run `RUSTFLAGS=\"-Z unstable-options --error-format=json\" cargo +nightly clippy` in container\n1. [ ] Somehow get the json back? Maybe via web api? Or maybe through Filesystem?\n\n- mend-rs itself will be compiled on stable (#16)\n- mend-rs will require Rust nightly to be installed for json error format (#17)\n\nCheck: https://firejail.wordpress.com/\nCheck clippy-service for dokku/travis deploy setup\n\n## Snippets\n\n```rust\n// Rate limit status:\nlet status = core.run(github.rate_limit().get()).unwrap();\nprintln!(\"{:#?}\", status);\n\n// Stuff:\nlet f = github.repo(\"phansch\", \"rust-clippy\").pulls().get(1).review_comments().create(\u0026opts);\nlet f = github.repo(\"phansch\", \"rust-clippy\").pulls().get(1).get();\nmatch core.run(f) {\n    Ok(pr) =\u003e println!(\"{:?}\", pr.patch_url),\n    Err(err) =\u003e println!(\"err {}\", err),\n}\n\n// ReviewCommentOptions:\nlet opts = ReviewCommentOptions {\n    body: \"abc\".to_string(),\n    commit_id: \"62733ca4cc6e9716b566a809dc3dd88f8b94690e\".to_string(),\n    path: \".travis.yml\".to_string(),\n    position: 5\n};\n ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphansch%2Fmend-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fphansch%2Fmend-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fphansch%2Fmend-rs/lists"}