{"id":27138710,"url":"https://github.com/franalgaba/pre-commit-cairo","last_synced_at":"2025-09-22T23:03:53.226Z","repository":{"id":39916883,"uuid":"484466117","full_name":"franalgaba/pre-commit-cairo","owner":"franalgaba","description":"Cairo hooks for pre-commit","archived":false,"fork":false,"pushed_at":"2022-05-21T18:35:50.000Z","size":180,"stargazers_count":17,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-08T04:54:42.832Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/franalgaba.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}},"created_at":"2022-04-22T14:35:49.000Z","updated_at":"2024-09-23T05:53:43.000Z","dependencies_parsed_at":"2022-09-24T17:56:53.636Z","dependency_job_id":null,"html_url":"https://github.com/franalgaba/pre-commit-cairo","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/franalgaba/pre-commit-cairo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/franalgaba%2Fpre-commit-cairo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/franalgaba%2Fpre-commit-cairo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/franalgaba%2Fpre-commit-cairo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/franalgaba%2Fpre-commit-cairo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/franalgaba","download_url":"https://codeload.github.com/franalgaba/pre-commit-cairo/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/franalgaba%2Fpre-commit-cairo/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276487484,"owners_count":25651133,"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-22T02:00:08.972Z","response_time":79,"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":[],"created_at":"2025-04-08T04:54:45.494Z","updated_at":"2025-09-22T23:03:53.203Z","avatar_url":"https://github.com/franalgaba.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# pre-commit-cairo\n\n[![Test and release](https://github.com/franalgaba/pre-commit-cairo/actions/workflows/release.yml/badge.svg?branch=main)](https://github.com/franalgaba/pre-commit-cairo/actions/workflows/release.yml)\n\nCairo hooks for pre-commit. See [pre-commit](https://github.com/pre-commit/pre-commit) for more details\n\n## Using pre-commit-cairo with pre-commit\n\nAdd this to your `.pre-commit-config.yaml`\n\n```yaml\n-   repo: https://github.com/franalgaba/pre-commit-cairo\n    rev: main  # Use the ref you want to point at\n    hooks:\n    -   id: cairo-lint\n    -   id: cairo-format\n```\n\n## Hooks available\n\n### `cairo-lint`\n\nChecks lint of Cairo contracts using [Amarna](https://github.com/crytic/amarna). If it fails a summary table with results is shown as shown below:\n\n![result](./img/lint_result.png)\n\nAmarna does not have a public release yet. So, to use this hook first you need to install Amarna in your project manually:\n\n`pip install git+https://github.com/crytic/amarna.git@main`\n\nor\n\n`poetry add git+https://github.com/crytic/amarna.git@main`\n\nAfter a public release for Amarna is made, the hook will install it automatically.\n\n### `cairo-format`\n\nChecks format of Cairo contracts using cairo-lang built in tool `cairo-format`. Command will be run with the `-i` flag.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffranalgaba%2Fpre-commit-cairo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffranalgaba%2Fpre-commit-cairo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffranalgaba%2Fpre-commit-cairo/lists"}