- Create a NuGet account at https://www.nuget.org
- Generate an API key:
- Go to https://www.nuget.org/account/apikeys
- Click "Create"
- Name: "LocalAI.NET Publishing" (or your preferred name)
- Expiration: 365 days
- Select "Push new packages and package versions"
- Glob Pattern: "LocalAI.NET*"
- Save the generated key securely
-
Update version in
LocalAI.NET/LocalAI.NET.csproj
:<Version>1.0.0</Version> <!-- Change this to new version -->
-
Clean and pack:
dotnet clean dotnet pack -c Release
-
Push to NuGet:
dotnet nuget push .\LocalAI.NET\bin\Release\LocalAI.NET.1.0.0.nupkg --api-key YOUR_API_KEY --source https://api.nuget.org/v3/index.json
Replace:
1.0.0
with your new version numberYOUR_API_KEY
with your NuGet API key
-
Wait 15-30 minutes for the package to appear on NuGet.org
- Use Semantic Versioning:
- MAJOR version for incompatible API changes
- MINOR version for backwards-compatible functionality
- PATCH version for backwards-compatible bug fixes
- Use C# latest features and best practices
- Follow Microsoft's C# Coding Conventions
- Use meaningful names for variables, methods, and classes
- Add XML documentation comments for public APIs
- Write unit tests for new features
- Ensure all tests pass before submitting PR:
dotnet test
- Fork the repository
- Create a feature branch
- Make your changes
- Update documentation and tests
- Submit a pull request
Open an issue on GitHub if you have questions or need help.