Installation
Forge.Repository targets .NET 10 and is published to NuGet.org . Installation is a two-step process: install the core package, then add one provider package for your target database.
Requirements
| Requirement | Minimum version |
|---|---|
| .NET SDK | 10.0 |
| Entity Framework Core | 10.0.x |
| C# language version | 13 (latest) |
Step 1 — Install the Core Package
The core package is always required regardless of which database you use. It contains all interfaces, base models, the criteria pattern, and the unit of work contract.
dotnet CLI
dotnet add package Forge.RepositoryStep 2 — Install a Provider Package
Install exactly one provider package matching your target database. Each provider pulls in the appropriate EF Core database driver as a transitive dependency.
SQL Server
dotnet add package Forge.Repository.SqlServerPulls in Microsoft.EntityFrameworkCore.SqlServer and Microsoft.Data.SqlClient.
Version pinning — always install the same version for both Forge.Repository and your provider package. For alpha builds, pin to the exact version rather than using a floating range to avoid unexpected breaking changes.
dotnet add package Forge.Repository --version 10.0.0
dotnet add package Forge.Repository.SqlServer --version 10.0.0Typical Project Layout
After installation your project will look something like this:
- OrderConfiguration.cs
- ProductConfiguration.cs
- CustomerConfiguration.cs
- AppDbContext.cs
- Order.cs
- Product.cs
- Customer.cs
- ActiveOrdersCriteria.cs
- OrderService.cs
- Program.cs
- MyApp.csproj
Verifying Installation
Run a quick build to confirm everything resolves:
dotnet buildIf you see CS0246 errors about missing types, make sure both packages are at the same version and your TargetFramework is set to net10.0.