{"id":23868073,"url":"https://github.com/suesslabs/litemigrator","last_synced_at":"2025-09-08T16:32:27.905Z","repository":{"id":43333831,"uuid":"205471567","full_name":"SuessLabs/LiteMigrator","owner":"SuessLabs","description":"SQLite Lite Migration Tool for .NET MAUI, Avalonia, Uno, and cross-platform apps. Created by Suess Labs and Xeno Innovations.","archived":false,"fork":false,"pushed_at":"2025-01-01T17:35:40.000Z","size":187,"stargazers_count":3,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"develop","last_synced_at":"2025-01-01T18:30:39.907Z","etag":null,"topics":["avalonia","database","dotnet","litemigrator","maui","migration","migrator","sql","sqlite","xamarin","xeno-innovations","xenoinc"],"latest_commit_sha":null,"homepage":"https://www.nuget.org/packages/LiteMigrator/","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SuessLabs.png","metadata":{"files":{"readme":"readme.md","changelog":"changelog.md","contributing":".github/Contributing.md","funding":null,"license":"license.txt","code_of_conduct":".github/Code-of-Conduct.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":".github/Security.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-08-30T23:51:29.000Z","updated_at":"2025-01-01T17:35:33.000Z","dependencies_parsed_at":"2025-01-01T18:30:42.387Z","dependency_job_id":null,"html_url":"https://github.com/SuessLabs/LiteMigrator","commit_stats":null,"previous_names":["suesslabs/litemigrator"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuessLabs%2FLiteMigrator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuessLabs%2FLiteMigrator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuessLabs%2FLiteMigrator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuessLabs%2FLiteMigrator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SuessLabs","download_url":"https://codeload.github.com/SuessLabs/LiteMigrator/tar.gz/refs/heads/develop","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":232327032,"owners_count":18505993,"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":["avalonia","database","dotnet","litemigrator","maui","migration","migrator","sql","sqlite","xamarin","xeno-innovations","xenoinc"],"created_at":"2025-01-03T11:17:24.494Z","updated_at":"2025-01-03T11:17:25.303Z","avatar_url":"https://github.com/SuessLabs.png","language":"C#","readme":"# SQLite Lite Migrator for cross-platform .NET\n\n\u003c!-- \u003cimg align=\"right\" width=\"90\" height=\"90\" src=\"https://raw.githubusercontent.com/SuessLabs/LiteMigrator/master/docs/logo.png\" /\u003e --\u003e\n[![](https://raw.githubusercontent.com/SuessLabs/LiteMigrator/master/docs/logo.png)]()\n\nLiteMigrator is a tiny cross-platform SQLite migration framework for .NET applications. This library was built for use with .NET MAUI 🐒, Avalonia, and Uno projects. So it needs to be quick, simple, and reliable when managing databases.\n\n**LiteMigrator** takes a \"_migrate-up_\" approach. In most app deployments, we usually move forward and rarely downgrade (_consider app stores_). This helps keep the library small and nimble. Previously known as, _SQLiteMigrator_.\n\n[![](https://img.shields.io/nuget/v/LiteMigrator?color=blue)](https://www.nuget.org/packages/LiteMigrator/)\n[![LiteMigrator Docs](https://img.shields.io/badge/docs-litemigrator-blue.svg)](https://github.com/SuessLabs/LiteMigrator/wiki)\n\n\u003e Breaking Change from 0.6.x to now:\n\u003e\n\u003e Namespace changed from `Xeno.LiteMigrator` to `LiteMigrator`\n\nBrought to you with nerd-love by [Suess Labs](https://suesslabs.com), sponsored by [Xeno Innovations](https://xenoinc.com).\n\n## Supported Platforms\n\nCheck out the sample project's source code [LiteMigrator.Sample](https://github.com/SuessLabs/LiteMigrator.Sample)\n\n| Platform | Status |\n|----------|--------|\n| Windows  | Yes\n| Linux    | Yes\n| Android  | Yes\n| iOS      | Yes\n\nContribute today and get your platform supported 👍\n\n## How to use it\n\nGet [LiteMigrator](https://www.nuget.org/packages/LiteMigrator) on NuGet today!\n\n## Getting Started\nDetailed instructions can be found on the [Using LiteMigrator](https://github.com/SuessLabs/LiteMigrator/wiki/Using-LiteMigrator) wiki page.\n\n1. Add **LiteMigrator** project to your solution\n2. Create a folder in your solution to hold the scripts\n3. Add SQL files as **Embedded Resources**\n   * You must use the naming convention, \"_YYYYMMDDhhmm-FileName.sql_\"\n4. Wire-up the controller\n\n\n\n### Use Case - .NET MAUI Basic Example\n\n```cs\n  // 1. Add a few `.sql` files as Embedded Resources to project\n  //    in the namespace `MyProject.Namespace.Scripts`\n  // 2. Execute the migrates as follows\n  //    This will create the DB in your MAUI app's AppData directory.\n  var dbPath = Path.Combine(FileSystem.AppDataDirectory, \"LiteMigrator.db3\");\n  var scriptNamespace = \"MyProject.Namespace.Scripts\";\n\n  using var migrator = new Migrator(dbPath, scriptNamespace);\n\n  // Install migration scripts\n  bool isSuccessful = await migrator.MigrateUpAsync();\n```\n\n### Use Case - Migration Management\n\n```cs\n  var dbPath = Path.Combine(FileSystem.AppDataDirectory, \"LiteMigrator.db3\");\n  var scriptNamespace = \"MyProject.Namespace.Scripts\";\n\n  using var migrator = new Migrator(dbPath, scriptNamespace);\n\n  // List of all embedded script files\n  var embeddedMigrations = migrator.Migrations.GetSortedMigrations();\n\n  // List of scripts installed\n  var installed = await migrator.GetInstalledMigrationsAsync();\n\n  // List of scripts waiting to be installed\n  var notInstalled = await migrator.GetMissingMigrationsAsync();\n\n  // Install migration scripts\n  bool isSuccessful = await migrator.MigrateUpAsync();\n```\n\n### Use Case 2 - Manually Destruct and Close Connection\n\n```cs\npublic async Task InstallMigrationsAsync()\n{\n  // Your EXE/DLL with the scripts\n  var dbPath = @\"C:\\TEMP\\MyDatabase.db3\";\n  var migsNamespace = \"MyProjNamespace.Scripts\";\n\n  var migrator = new Migrator(dbPath, migsNamespace);\n  bool = success = await migrator.MigrateUpAsync();\n\n  // Required after v0.6\n  migrator.Dispose();\n}\n```\n\n## How to Contribute\n\nGive it a test drive and support making LiteMigrator better :)\n\n1. Fork on GitHub\n2. Create a branch\n3. Code (_and add tests_)\n4. Create a Pull Request (_PR_) on GitHub\n   1. Target the ``develop`` branch and we'll get it merged up to ``master``\n   2. Target the ``master`` branch for hotfixes\n5. Get the PR merged\n6. Welcome to our contributors' list!\n\nThis project could use your assistance to crush any limitations.\n\nPlease visit the [Known Limitations](https://github.com/SuessLabs/LiteMigrator/wiki/Known-Limitations) wiki page\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsuesslabs%2Flitemigrator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsuesslabs%2Flitemigrator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsuesslabs%2Flitemigrator/lists"}