Converting to use Litium NuGet packages (if you are running Litium 4.x)

If you are running Litium 4.x, we recommend that you convert your solution to use Litium NuGet packages for easy upgrades.

Note: If you If you have replaced any of the infrastructure components in Litium and want to update the solution to use NuGet, you should follow the instructions in the section Advanced users below.

After loading your solution, follow these steps in Visual Studio:

  1. Open NuGet Package Manager Console from Tools > NuGet Package Manager > NuGet Package Manager Console.
  2. Execute the following command in NuGet Package Manager Console to download the Convert to nuget script:
    (new-object Net.WebClient).DownloadFile("https://nuget.litium.com/tools/ConvertToNuget.ps1",  (((get-location).Path) + "\LitiumConvertToNuget.ps1"))
  3. Execute the following command in the Nuget Package Manager Console to start the conversion to use nuget packages:
    ./LitiumConvertToNuget.ps1

Advanced users

When you run the LitiumConvertToNuget command in NuGet Package Manager Console, Litium will be updated with the default packages for the entire solution, from dependency injection and logging to search library. If you have replaced any of the infrastructure components in Litium and want to update the solution to use NuGet, you should follow these steps in Visual Studio instead of the above instructions.

  1. Open NuGet Package Manager Console from Tools > NuGet Package Manager > NuGet Package Manager Console.
  2. Execute the following command in NuGet Package Manager Console to download the Convert to nuget script:
    (new-object Net.WebClient).DownloadFile("https://nuget.litium.com/tools/ConvertToNuget.ps1",  (((get-location).Path) + "\LitiumConvertToNuget.ps1"))
  3. Execute the following command in the Nuget Package Manager Console to begin the conversion to use nuget packages:
    ./LitiumConvertToNuget.ps1 -CoreOnly

The above command will only update your solution to use NuGet, but no infrastructure packages are added. If you are using infrastructure packages in any of your projects, you need to add either your own replacement for the package or the package itself. All commands are executed in the NuGet Package Manager Console. You select the project in the dropdown list at the top of the NuGet Package Manager Console.

Install-Package Litium.Infrastructure.InversionOfControl
Install-Package Litium.Infrastructure.Logging.NLog
Install-Package Litium.Infrastructure.Logging.NLog.Extensions
Install-Package Litium.Infrastructure.Search.Lucene
Install-Package Litium.Infrastructure.WebLog.Exceptional
Is this page helpful?
Thank you for your feedback!