Kpm is the package manager for the new KRuntime. Instructions on how to install the KRuntime command line utilities on your developer machine can be found on the aspnet Home repo. Once you have kvm and a version of the KRuntime set up you will have kpm available as well.
Now you can run kpm build
on your class libraries project location. Output should be something like this:
kpm build src\ClassLibrary1\
ClassLibrary1 -> C:\Users\username\Documents\Visual Studio 14\Projects\WebApplication1\src\ClassLibrary1\bin\Debug\ClassLibrary1.1.0.0.nupkg
ClassLibrary1 -> C:\Users\username\Documents\Visual Studio 14\Projects\WebApplication1\src\ClassLibrary1\bin\Debug\ClassLibrary1.1.0.0.symbols.nupkg
Build succeeded.
0 Warnings(s)
0 Error(s)
Time elapsed 00:00:01.7556414
The easiest way to add a reference to a class project is to do it in your project.json, assuming you have it in the same solution. Here is an example project.json from a web application, which references a class library called ClassLibrary1.
{
"webroot" : "wwwroot",
"exclude": "wwwroot/**/*.*",
"dependencies": {
"Microsoft.AspNet.Server.IIS": "1.0.0-alpha4",
"ClassLibrary1": ""
},
"frameworks" : {
"aspnet50" : { },
"aspnetcore50" : { }
}
}
If you want to set up a NuGet feed you can read the official NuGet documentation to see how that is done. Copy the outputs of kpm build
into your NuGet feed.
Note: VS14 CTP4 only works with alpha4 of the KRuntime. If you want to use VS14 for vNext without errors popping up you need to downgrade your KRuntime to version 1.0.0-alpha4.