{"id":17163885,"url":"https://github.com/teemu/sqlsugar","last_synced_at":"2026-05-19T09:06:50.639Z","repository":{"id":63529852,"uuid":"568434238","full_name":"Teemu/sqlsugar","owner":"Teemu","description":"Automatic migrations for SQLAlchemy 🍭","archived":false,"fork":false,"pushed_at":"2022-11-20T21:24:01.000Z","size":26,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-27T03:23:35.066Z","etag":null,"topics":["alembic","autogenerated","database","migrations","sqlalchemy"],"latest_commit_sha":null,"homepage":"","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/Teemu.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-11-20T14:23:56.000Z","updated_at":"2022-11-20T21:43:52.000Z","dependencies_parsed_at":"2023-01-23T06:01:30.600Z","dependency_job_id":null,"html_url":"https://github.com/Teemu/sqlsugar","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":"simonw/python-lib-template-repository","purl":"pkg:github/Teemu/sqlsugar","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Teemu%2Fsqlsugar","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Teemu%2Fsqlsugar/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Teemu%2Fsqlsugar/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Teemu%2Fsqlsugar/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Teemu","download_url":"https://codeload.github.com/Teemu/sqlsugar/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Teemu%2Fsqlsugar/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264559643,"owners_count":23628040,"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":["alembic","autogenerated","database","migrations","sqlalchemy"],"created_at":"2024-10-14T22:50:17.940Z","updated_at":"2026-05-19T09:06:50.608Z","avatar_url":"https://github.com/Teemu.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SQLSugar - Automatic migrations for SQLAlchemy\n\n![sqlsugar](https://user-images.githubusercontent.com/53298/202926852-d212a4dc-ee3c-419f-851c-6b814ad3d254.jpg)\n\n[![PyPI](https://img.shields.io/pypi/v/sqlsugar.svg)](https://pypi.org/project/sqlsugar/)\n[![Changelog](https://img.shields.io/github/v/release/Teemu/sqlsugar?include_prereleases\u0026label=changelog)](https://github.com/Teemu/sqlsugar/releases)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/Teemu/sqlsugar/blob/main/LICENSE)\n\nThis library is for you if you want to use a real database without spending time to generate migrations. This is experimental and you should switch to [Alembic](https://alembic.sqlalchemy.org/en/latest/) as your project matures. This only supports adding new tables, columns and indexes.\n\n## Installation\n\nInstall this library using `pip`:\n\n    pip install sqlsugar\n\n## Usage\n\nSee our examples for [SQLAlchemy](https://github.com/Teemu/sqlsugar/blob/main/examples/use_with_sqlalchemy.py) and [SQLModel](https://github.com/Teemu/sqlsugar/blob/main/examples/use_with_sqlmodel.py).\n\n```python\nfrom sqlsugar import migrate\n\n# You only need this command to handle creating tables \u0026 running migrations\nmigrate(engine.connect(), Base.metadata)\n```\n\n## How it works\n\nWe use Alembic to autogenerate the difference between the models you have defined with SQLAlchemy and the database. We then execute operations that create tables, add new columns or add new indexes. That is often all that's needed for rapid prototyping or running very small hobby projects.\n\nHowever, we don't support renaming columns, dropping columns or removing tables. You should switch to using Alembic as your needs evolve. Alternatively, you can try running those migrations manually.\n\n## Development\n\nTo contribute to this library, first checkout the code. Then create a new virtual environment:\n\n    cd sqlsugar\n    python -m venv .venv\n    source .venv/bin/activate\n\nNow install the dependencies and test dependencies:\n\n    pip install -e '.[test]'\n    pre-commit install\n\nTo run the tests:\n\n    pytest\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fteemu%2Fsqlsugar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fteemu%2Fsqlsugar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fteemu%2Fsqlsugar/lists"}