I have created an Console Application(.Net Core) in Visual Studios MacOS Preview. In the project solution I don't see my program.cs also other things are not available it says Project not built in active configuration
whereas the project solution should look something like this
I have installed .net core for macOS. Also done with Homebrew configurations. I already had openssl & [email protected] installed in osx so when I try to re-install openssl with homebrew it says
Warning: openssl is a keg-only and another version is linked to opt.
Use `brew install --force` if you want to install this version
On the other part to be sure that .net core works fine. I just compiled .net core C# application in Visual Studio Code.
Visual Studio for Mac makes it easy to develop your app's service with its support for the latest ASP.NET Core Web development platform. ASP.NET Core runs on the latest evolution of the . NET platform and runtime.
Right-click on the project node and select Options. You can also double-click on the project node to bring up the Project Options dialog. Select Add to create a new configuration. You can also copy any of the existing configurations.
If you want to build multiple configurations and platforms in one action, you can use the Build > Batch Build option in Visual Studio. To access this feature, press Ctrl+Q to open the search box, and enter Batch build .
It looks like you do not have the .NET Core SDK 1.0.0-rc4 installed.
Without the SDK installed Visual Studio for Mac Preview 3 will not find any SDK MSBuild files to import which results in no Debug/Release configurations being added to the project.
Visual Studio for Mac looks in the /usr/local/share/dotnet/sdk/ directory for the latest sdk. If there are no subdirectories in that directory then you do not have the SDK installed.
Also there are no files shown in the project which will also occur if there is no SDK found.
Currently Visual Studio for Mac does not have good error reporting about the missing SDK but this is planned for a future release.
I got the same issue after VS update to build 1077. To resolve this issue you just need install .NET Core SDK 1.0.0-rc4 and reinstall Mono 4.8, you can get it here.
These information I got from changelog page https://developer.xamarin.com/releases/vs-mac/preview/vs-mac-preview1/
I hope this will help.
For me on .netcore library project.
Remove project from solution (Right click on project > Delete > Remove)
And add it again. (Right click to solution > Add > Add Exist Project..)
Make sure SDK was already installed as Matt Ward mentioned.
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