T4MVC / R4MVC

R4MVC is a Roslyn code generator for ASP.NET Core MVC apps that creates strongly typed helpers that eliminate the use of literal strings in many places
Apache License 2.0
157 stars 48 forks source link

Cross Plaform #113

Open matthewblott opened 5 years ago

matthewblott commented 5 years ago

I'm not sure if this is an issue or a feature request. I installed R4Mvc.Tools on macOS and get the following error when I run the r4mvc command.

Sorry, this tol is only available on Windows based platforms at this time.

I noticed this comment in issue #1 it says there's a dependency on MSBuild which wasn't cross platform at the time (but it is now). I work on macOS and deploy to Linux. So should R4Mvc.Tools work on non Windows platforms or is this something that still requires work?

Thanks :-)

artiomchi commented 5 years ago

Hi Matthew,

Unfortunately this is still the case. While the dotnet compiler is cross platform, they don't have a simple way to programatically load a project in your own code and compile/analyse it.

Currently this is done using the Microsoft.CodeAnalysis.Workspaces.MSBuild package, which is compiled against .NET 4.6, instead of .NET standard. There's a discussion about this on the roslyn project here: dotnet/roslyn#17974

I've tried using Buildayzer earlier this year, and have had some issues with it, but I might try it again this month, and see if I get any success with it.

matthewblott commented 5 years ago

Thanks for the response @artiomchi :-)

matthewblott commented 5 years ago

@artiomchi did you get any further success trying Buildayzer again?

vborioni-onit commented 4 years ago

Hi, what do we need to make it run other than on windows ? I see that Microsoft.CodeAnalysis.Workspaces.MSBuild is compiled for netframework and netcore app since version 3, is it enough ?

valeriob commented 4 years ago

Hi @artiomchi do you think you can give some updated feedback on the subject ?

valeriob commented 4 years ago

Hi @artiomchi i just tested it in linux and it works, it just needs to remove the constraint :D can you pls help me with that ? I tested with a custom build of r4mvc.tool targeting netcoreapp3.1

image

valeriob commented 4 years ago

hi @artiomchi i hope you are all right, would you mind to give me an hand on this topic ? i think it will just work, but i do not know how the boilerplate to run the tool works :(