Skip to content

Nightly Builds

Gerald Versluis edited this page Jan 15, 2025 · 7 revisions

.NET MAUI Version Pinning & Nightly Build Integration (youtube.com)

Starting with .NET 8, it is possible to test out nightly builds, builds from Pull Requests, or any other set of .NET MAUI NuGet packages.

NuGet Feed

Nightly NuGet Package Feed URL "https://pkgs.dev.azure.com/xamarin/public/_packaging/maui-nightly/nuget/v3/index.json"

Warning

The versions on the nightly feed are ordered by version number, not date. Make sure that you check the "Include prereleases" checkbox in your NuGet explorer and select the version that mentions "nightly" in the version.

To add this NuGet feed to your Visual Studio, please refer to the docs.

Alternatively, you can use the dotnet CLI to add a source directly. For example:

dotnet nuget add source https://dev.azure.com/xamarin/public/_artifacts/feed/maui-nightly -n maui-nightly

Or do dotnet new nugetconfig to create a NuGet.config file and add this content:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <packageSources>
    <clear />
    <add key="maui-nightly" value="https://dev.azure.com/xamarin/public/_artifacts/feed/maui-nightly" />
  </packageSources>
</configuration>

Consume NuGet in .NET MAUI project

New .NET MAUI projects contain the following package references, if these are not there, you can add them manually:

  • <PackageReference Include="Microsoft.Maui.Controls" Version="$(MauiVersion)" />
  • <PackageReference Include="Microsoft.Maui.Controls.Compatibility" Version="$(MauiVersion)" />

The Version is set by default to the $(MauiVersion) variable which will cause the version of the .NET MAUI Workload installed to always be substituted in its place. You can change this version either by editing the .csproj file directly, or by using the NuGet Package Manager to a newer version such as one of the 8.0.0-nightly versions from feed.

You will still need to occasionally update your .NET MAUI Workloads (typically you will do this by updating Visual Studio), and some newer versions of the NuGet packages may produce errors if you attempt to install them on older workload and/or SDK versions.

Clone this wiki locally