{"id":15724103,"url":"https://github.com/huluti/doctrinerelationsanalyser","last_synced_at":"2025-04-30T15:45:27.888Z","repository":{"id":248848586,"uuid":"830016575","full_name":"Huluti/DoctrineRelationsAnalyser","owner":"Huluti","description":"A Symfony bundle that provides tools for analyzing Doctrine relationships","archived":false,"fork":false,"pushed_at":"2024-10-15T09:04:18.000Z","size":83,"stargazers_count":12,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-22T22:37:30.407Z","etag":null,"topics":["doctrine","mit","php","relations","symfony","symfony-bundle","vizualizer"],"latest_commit_sha":null,"homepage":"","language":"PHP","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/Huluti.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":".github/FUNDING.yml","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},"funding":{"liberapay":"hugoposnic"}},"created_at":"2024-07-17T12:48:40.000Z","updated_at":"2025-02-25T20:32:13.000Z","dependencies_parsed_at":"2024-10-24T20:40:43.622Z","dependency_job_id":null,"html_url":"https://github.com/Huluti/DoctrineRelationsAnalyser","commit_stats":{"total_commits":51,"total_committers":1,"mean_commits":51.0,"dds":0.0,"last_synced_commit":"71bf618d442a36379308606b97a66527461c9350"},"previous_names":["huluti/doctrinerelationsanalyser"],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Huluti%2FDoctrineRelationsAnalyser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Huluti%2FDoctrineRelationsAnalyser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Huluti%2FDoctrineRelationsAnalyser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Huluti%2FDoctrineRelationsAnalyser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Huluti","download_url":"https://codeload.github.com/Huluti/DoctrineRelationsAnalyser/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246355198,"owners_count":20763961,"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":["doctrine","mit","php","relations","symfony","symfony-bundle","vizualizer"],"created_at":"2024-10-03T22:14:47.078Z","updated_at":"2025-03-31T15:30:58.718Z","avatar_url":"https://github.com/Huluti.png","language":"PHP","funding_links":["https://liberapay.com/hugoposnic"],"categories":[],"sub_categories":[],"readme":"# Doctrine Relations Analyzer\n\n![Packagist Version](https://img.shields.io/packagist/v/huluti/doctrine-relations-analyser)\n![Packagist License](https://img.shields.io/packagist/l/huluti/doctrine-relations-analyser)\n![Packagist Downloads](https://img.shields.io/packagist/dt/huluti/doctrine-relations-analyser)\n\n## Overview\n\nDoctrine Relations Analyzer is a tool designed to analyze and visualize cascade relationships within Doctrine ORM entities in Symfony projects. It helps developers understand how deletion operations propagate through related entities and assists in identifying potential issues or optimizations in data management strategies.\n\n\u003e [!NOTE]\n\u003e**Why is it important?**\n\u003e\n\u003eManaging cascade operations, especially deletions, is crucial to avoid unintentional data loss. This tool provides a human-readable summary to help developers review and understand these relationships, ensuring they are intentional and correctly implemented.\n\n\u003e [!WARNING]\n\u003e This project is a work in progress. Contributions and feedback are welcome.\n\n## Usage\n\n### Requirements\n\n- PHP \u003e= 8.1\n- Symfony \u003e= 6.4\n- Doctrine 2|3\n- Graphviz package:\n    - **For Alpine Linux:** `graphviz fontconfig ttf-freefont`\n\n### Installation\n\n#### Applications that use Symfony Flex\n\nOpen a command console, enter your project directory and execute:\n\n```console\ncomposer require --dev huluti/doctrine-relations-analyser\n```\n\n#### Applications that don't use Symfony Flex\n\n##### Step 1: Download the Bundle\n\nOpen a command console, enter your project directory and execute the\nfollowing command to download the latest stable version of this bundle:\n\n```console\ncomposer require --dev huluti/doctrine-relations-analyser\n```\n\n##### Step 2: Enable the Bundle\n\nThen, enable the bundle by adding it to the list of registered bundles\nin the `config/bundles.php` file of your project:\n\n```php\n// config/bundles.php\n\nreturn [\n    // ...\n    DoctrineRelationsAnalyserBundle\\DoctrineRelationsAnalyserBundle::class =\u003e ['dev' =\u003e true, 'test' =\u003e true],\n];\n```\n\n### Usage\n\n    php bin/console doctrine-relations-analyser:analyse\n\n#### Examples\n\nTo check deletion relations of two entities in a graph:\n\n    php bin/console doctrine-relations-analyser:analyse -o data/ -g --entities=\"App\\\\Entity\\\\User,App\\\\Entity\\\\Workspace\" -m deletions\n\n#### Command-line Arguments\n\n- --entities: Optional. Comma-separated list of entities to analyze\n- -m, --mode: Optional. Analysis mode (all, deletions) [default: \"all\"]\n- -o, --output: Optional. Output path for reports generated\n- -g, --graph: Optional. Generate Graphviz graph\n- --graph-format: Optional. Graph image format (png, svg) [default: \"png\"]\n- -V, --version: Optional. Display help for the given command. When no command is given display help for the list command\n- -h, --help: Optional. Display this application version\n\n## Limitations\n\n- Only work with first joinColumn for now.\n\n## Contributions\n\nContributions are welcome! If you have ideas for improvements, new features, or bug fixes, please open an issue or a pull request.\n\n## Interesting readings\n\n- [How to delete… not to delete yourself?](https://accesto.com/blog/how-to-delete-to-not-delete-yourself)\n\n## Donations\n\nDo you like the tool? Would you like to support its development? Feel free to donate 🤗\n\n[![Liberapay receiving](https://img.shields.io/liberapay/receives/hugoposnic)](https://liberapay.com/hugoposnic)\n[![Liberapay patrons](https://img.shields.io/liberapay/patrons/hugoposnic)](https://liberapay.com/hugoposnic)\n\n## License\n\nThis project is licensed under the MIT License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhuluti%2Fdoctrinerelationsanalyser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhuluti%2Fdoctrinerelationsanalyser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhuluti%2Fdoctrinerelationsanalyser/lists"}