In the new ASP.NET 5 projects, there are multiple ways / places to control the .NET versions:
global.json
dnvm list
dnvm list
Which of these are the same (apart from the first two) and what do they all do?
The dnx
in global.json
is only used by VS. No one else uses it and if you run the application outside of VS, there is no guarantee that it'll use that version.
The dnx
used to run a particular application is set in two ways:
dnx
. E.g: C:\dnx\dnx.exe . run
dnx
on the PATH resolved according to your OS' PATH resolution (we don't control that).When you run dnvm use <version>
, that particular version is added to the path and it will be used by that particular process and it's child processes. If you run dnvm use -p <version>
, that version of dnx
is added to the user's PATH in addition to the process' PATH.
For VS, if no version is specified in global.json
by default it uses the dnx
under the default
alias. The default alias is updated when you run dnvm upgrade
or dnvm use -p
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With