I tried the following command on ASP.NET Core 1.1 project with .csproj file:
dotnet razor-precompile --output OutputFolder
I expected the views to be compiled and placed on the OutputFolder
I get error:
Could not find file 'C:\...\project.json'
My project is using ASP.NET Core 1.1 with **.csproj** file ... I do not have a project.json anymore.
Am I missing something?
dotnet --info output:
NET Command Line Tools (1.0.0-preview4-004124)
Product Information:
Version: 1.0.0-preview4-004124
Commit SHA-1 hash: eb8e0cfa40
Runtime Environment:
OS Name: Windows
OS Version: 10.0.10586
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\1.0.0-preview4-004124
Our tools do not yet work with csproj. They are still project.json based
But yet you release a Visual Studio 2017 RC with go live? I have the same problem. If i want to run my solution on IIS on staging server, now my clients can not see the progress :-(
What's the point then for releasing 2017 RC and also moving forward to csproj instead of project.json if you don't support the whole bits? So I have to convert everything back to VSS 2015 now?
@davidfowl
Our tools do not yet work with csproj. They are still project.json based
Which tools? Are you talking about dotnet publish-iis and dotnet razor-precompile?
These were the ones that I found needed a project.json file ...
But isn't dotnet publish-iis going to be removed? Isn't Microsoft.NET.Sdk.Web" Version="1.0.0-alpha-20161104-2-112 doing the Web.config transformation that dotnet publish-iis was doing?
You should clarify things because people are releasing projects and this create some problems.
@hyuksel
I think you don't need dotnet razor-precompile to publish it to the server ...
Only dotnet publish-iis for the Web.config transformation which I think is handled by Microsoft.NET.Sdk.Web" Version="1.0.0-alpha-20161104-2-112
About Visual Studio 2017 RC I think it is quite unstable ... I tried to use it with a few NET Core projects and got only problems ... I moved to Visual Studio Code and for now is working really well. Just a suggestion ...
I just have to apologize for the confusing place we are in. .NET Core 1.0 and 1.1 runtimes are both RTM and fully supported. Any application you build on either of those frameworks is completely go live, can be run in production and you can call and our support teams will help you out.
The tooling is what is in "preview" and it will RTM with Visual Studio 2017. We have the Visual Studio 2015 based project.json based tooling which is full featured and stable. With Visual Studio 2017 RC we released an alpha version of the new .csproj based tooling which is not as stable. We have some updates to the RC that are coming that will increase the stability before RTM.
Are there any docs or updates for how we setup pre-compiled views using the new csproj project system?
Latest info found here for csproj view precompilation
https://github.com/aspnet/MvcPrecompilation/issues/71
Is there a template for the new CSPROJ format anywhere? This would be really useful.
And you would only need to update it when a new version is released ...
@RehanSaeed It's a little bit buried perhaps, but the PJ doc mention is here: https://docs.microsoft.com/en-us/aspnet/core/mvc/views/razor#view-compilation and the upcoming csproj mention is in here (scroll down to it): https://github.com/aspnet/Docs/blob/csproj/aspnetcore/mvc/views/razor.md
@mdmoura The templates are at: https://github.com/aspnet/Templates/tree/dev/src/BaseTemplates
I don't think there is a doc version for a general template yet. You can get some addl info in this doc and the docs that appear in the table of contents around it: https://docs.microsoft.com/en-us/dotnet/articles/core/preview3/tools/csproj
Most helpful comment
I just have to apologize for the confusing place we are in. .NET Core 1.0 and 1.1 runtimes are both RTM and fully supported. Any application you build on either of those frameworks is completely go live, can be run in production and you can call and our support teams will help you out.
The tooling is what is in "preview" and it will RTM with Visual Studio 2017. We have the Visual Studio 2015 based project.json based tooling which is full featured and stable. With Visual Studio 2017 RC we released an alpha version of the new .csproj based tooling which is not as stable. We have some updates to the RC that are coming that will increase the stability before RTM.