Aiursoft.DbTools.InMemory 8.0.3

dotnet add package Aiursoft.DbTools.InMemory --version 8.0.3
NuGet\Install-Package Aiursoft.DbTools.InMemory -Version 8.0.3
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Aiursoft.DbTools.InMemory" Version="8.0.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Aiursoft.DbTools.InMemory --version 8.0.3
#r "nuget: Aiursoft.DbTools.InMemory, 8.0.3"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install Aiursoft.DbTools.InMemory as a Cake Addin
#addin nuget:?package=Aiursoft.DbTools.InMemory&version=8.0.3

// Install Aiursoft.DbTools.InMemory as a Cake Tool
#tool nuget:?package=Aiursoft.DbTools.InMemory&version=8.0.3

DBTools

MIT licensed Pipeline stat Test Coverage NuGet version (Aiursoft.CSTools) ManHours

DbTools are Aiursoft's common database tools. It contains a lot of useful database tools for developers.

Installation

To install Aiursoft.DbTools to your project from nuget.org:

dotnet add package Aiursoft.DbTools

Usage

Easier to register DbContext:

SQLite

var services = new ServiceCollection();
services.AddAiurSqliteWithCache<MyDbContext>("Data Source=app.db");

var built = services.BuildServiceProvider();
var context = built.GetRequiredService<MyDbContext>();

SQL Server

var services = new ServiceCollection();
services.AddAiurSqlServerWithCache<MyDbContext>("Server=(localdb)\\mssqllocaldb;Database=DebugTrusted_Connection=True;MultipleActiveResultSets=true");

var built = services.BuildServiceProvider();
var context = built.GetRequiredService<MyDbContext>();

Easier to update database:

var hostBuilder = Host.CreateDefaultBuilder();
hostBuilder.ConfigureServices(services => 
    services.AddAiurSqliteWithCache<MyDbContext>(@"DataSource=app.db;Cache=Shared")
);
var host = hostBuilder.Build();

// Now update:
await host.UpdateDbAsync<MyDbContext>(UpdateMode.CreateThenUse);

How to contribute

There are many ways to contribute to the project: logging bugs, submitting pull requests, reporting issues, and creating suggestions.

Even if you with push rights on the repository, you should create a personal fork and create feature branches there when you need them. This keeps the main repository clean and your workflow cruft out of sight.

We're also interested in your feedback on the future of this project. You can submit a suggestion or feature request through the issue tracker. To make this process more effective, we're asking that these include more information to help define them more clearly.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on Aiursoft.DbTools.InMemory:

Package Downloads
Aiursoft.SDK

The base class, tools and extends for Aiursoft web apps.

Aiursoft.DbTools.Switchable

Nuget package of 'Switchable' provided by Aiursoft

GitHub repositories (1)

Showing the top 1 popular GitHub repositories that depend on Aiursoft.DbTools.InMemory:

Repository Stars
AiursoftWeb/Infrastructures
Mirror of: https://gitlab.aiursoft.cn/aiursoft/infrastructures
Version Downloads Last updated
8.0.3 122 3/17/2024
8.0.2 79 3/17/2024
8.0.1 71 2/25/2024
8.0.0 164 2/19/2024
7.0.19 108 2/14/2024
7.0.18 83 2/4/2024
7.0.17 73 2/2/2024
7.0.16 72 2/2/2024
7.0.15 77 1/30/2024
7.0.14 111 1/10/2024
7.0.13 98 1/4/2024
7.0.12 466 12/30/2023
7.0.11 116 12/24/2023
7.0.10 142 12/1/2023
7.0.9 264 11/26/2023
7.0.8 251 11/18/2023
7.0.7 149 11/12/2023
7.0.6 198 11/2/2023
7.0.5 113 11/2/2023
7.0.4 173 10/31/2023
7.0.3 122 10/27/2023
7.0.2 246 10/11/2023
7.0.1 311 9/13/2023
7.0.0 217 9/5/2023
6.0.32 191 8/4/2023
6.0.31 143 8/3/2023
6.0.30 161 7/11/2023
6.0.29 343 6/30/2023