Canonical.DistroInfo.Static 1.0.0-preview.1.20260907.3

This is a prerelease version of Canonical.DistroInfo.Static.
dotnet add package Canonical.DistroInfo.Static --version 1.0.0-preview.1.20260907.3
                    
NuGet\Install-Package Canonical.DistroInfo.Static -Version 1.0.0-preview.1.20260907.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="Canonical.DistroInfo.Static" Version="1.0.0-preview.1.20260907.3" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Canonical.DistroInfo.Static" Version="1.0.0-preview.1.20260907.3" />
                    
Directory.Packages.props
<PackageReference Include="Canonical.DistroInfo.Static" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Canonical.DistroInfo.Static --version 1.0.0-preview.1.20260907.3
                    
#r "nuget: Canonical.DistroInfo.Static, 1.0.0-preview.1.20260907.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.
#:package Canonical.DistroInfo.Static@1.0.0-preview.1.20260907.3
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Canonical.DistroInfo.Static&version=1.0.0-preview.1.20260907.3&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Canonical.DistroInfo.Static&version=1.0.0-preview.1.20260907.3&prerelease
                    
Install as a Cake Tool

Canonical.DistroInfo.Static

NuGet License: GPL-3.0-only

This packages is currently published as a pre-release version and the public API may still change. We provide no official support; issues are addressed on a best-effort basis.

Compile-time complement to Canonical.DistroInfo. Provides static instances of the release data from the distro-info CSV files, eliminating the runtime file dependency — useful in minimal containers, on non-Debian hosts, and in unit tests that need deterministic data.

Installation

dotnet add package Canonical.DistroInfo.Static --prerelease

Usage

using Canonical.DistroInfo.Ubuntu;

// No file access and no async: the data is baked into the assembly.
var noble = UbuntuReleases.NobleNumbat;

Console.WriteLine(noble.Version);       // 24.04 LTS
Console.WriteLine(noble.ShortVersion);  // 24.04
Console.WriteLine(noble.IsLts);         // True

// The full collection exposes the same query API as Canonical.DistroInfo.
var lts = UbuntuReleases.Collection.GetLatestReleasedLts();

if (UbuntuReleases.Collection.TryGetBySeries("noble", out var release))
    Console.WriteLine(release == noble); // True

UbuntuReleases.Collection is an UbuntuReleaseInfoCollection, so every lifecycle query from Canonical.DistroInfo (GetDevel, GetAllStandardSupported, GetAllEsmSupported, …) behaves identically — only the data source differs.

Choosing between the two packages

Canonical.DistroInfo Canonical.DistroInfo.Static
Data source distro-info-data CSV files, read at runtime snapshot embedded at build time
Requires distro-info-data yes no
Picks up new releases automatically, when the system data is updated only by upgrading this package
API shape async loading direct static access

Both can be combined: read from disk when the data is available and fall back to the embedded snapshot otherwise.

What's in this package

  • UbuntuReleases — named release constants (e.g. NobleNumbat) plus Collection.

Static Debian data (DebianReleases) is not populated yet.

Contributing and support

This library is maintained on a best-effort basis and are not covered by Canonical support agreements. Bug reports and pull requests are welcome via GitHub Issues and pull requests.

License

Copyright 2026 Canonical Ltd.

SPDX-License-Identifier: GPL-3.0-only

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 3, as published by the Free Software Foundation.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranties of MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

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

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.0.0-preview.1.20260907.3 66 9/7/2026
1.0.0-preview.1.20260907.2 64 9/7/2026
1.0.0-preview.1.20260907 58 9/7/2026