This will probably be the 1st of many questions. I'm asking about the .net cli as it relates to asp.net core 1.0. I was keeping up until version (RC2) where i think the .net CLI was introduced and DNX, DNU, & DNVM where killed. To be honest i loved the way DNX, DNU, & DNVM worked. I'm not sure i like the decision to move to the .net cli but it "might" be my lack of understanding which i'm trying to clear up. One of the things i was REALLY looking forward to was the ability to use the newest/greatest version of .net without asking my admin to install the newest .net framework on the server which would force every app on that server to use the same framework.
I've watch a variety of videos on the .net CLI. The latest one with Scott Hunter: https://channel9.msdn.com/Events/DevDays/DevDays-Latam-2016/NET-CLI
From my understanding .net cli is kind of like the .net framework but a mini .net framework that will be shared on the machine that will be shared for many apps. So if i want to use the newest & greatest version of .net i again have to get the sysadmin to
install the latest version of the .net cli on the server right? I can't just bundle it with my app? If this is true i think this is definitely a step backwards rather than a step forwards. During the video after created an app with 'dotnet new' Scott makes
a change to the project.json:
{"version": "1.0.0-*","buildOptions": {"debugType": "portable","emitEntryPoint": true },"dependencies": {},"frameworks": {"netcoreapp1.0": {"dependencies": {"Microsoft.NETCore.App": { /*"type": "platform",*/"version": "1.0.0" } },"imports": "dnxcore50","runtimes": {"win10-x64": {} } } } }
I got excited because when he did a publish he got some dlls in the directory which seemed to be all the framework dlls. But when i attempted to do the same:
I commented out exactly what he commented out "type" and added the runtimes tag but when i try to build i get the following error:
Can not find runtime target for framework '.NETCoreApp,Version=v1.0' compatible with one of the target runtimes: 'win10-
x64, win81-x64, win8-x64, win7-x64'. Possible causes:
1. The project has not been restored or restore failed - run `dotnet restore`
2. The project does not list one of 'win10-x64, win81-x64, win8-x64, win7-x64' in the 'runtimes' section.
3. You may be trying to publish a library, which is not supported. Use `dotnet pack` to distribute libraries.
As you can see it didn't work even though i added the runtimes flag.
So are my hopes crushed? Will we have to get sysadmins to install the newest version of the dotnet cli on the server and we can't bundle the framework with our app? Yes i understand the dotnetcli will have the older versions of the .net standard library too but that is still going to require a sysadmin to install it on the server. With the DNVM it was so easy to update it and also to add new version of the framework. I hope i'm just confused and don't quite understand how the dotnet cli works and everything is still possible.