📜 ⬆️ ⬇️

We write and run ASP.NET vNext applications on Mac

ASP.NET has risen from the ashes and takes confident steps to conquer the world! First, Microsoft opened part of the .NET source code and continues to open it. The new version of ASP.NET vNext from the very beginning is open source and is hosted on GitHub . Secondly, from now on .NET will be cross-platform, exactly like the developed web server. This means that you can develop ASP.NET vNext web applications in your cozy Macashechkas and Ubuntas.
What I immediately decided to use.
IMHO. I think you do not need to explain about the beautiful syntax of C #, strong typing and high speed work.
As for ASP.NET, everything was sad before, but over the past few years, MS has made great progress in developing the ASP.NET MVC web framework by taking best practices from RoR, Laravel and others. And when several months ago they officially announced that they were opening the source code of their framework and were becoming cross-platform, the flame of love for them flared up again.


To start developing on ASP.NET vNext under the Mac you need to install the following software, frameworks and package managers:


Sublime Text 3 installation


Sublime Text is a fast cross-platform program source editor. Supports plugins in the Python programming language.

Sublime Text is not free or open source software; however, some of its plugins are licensed and developed and supported by the developer community.
')
Go to the official site and download. An unregistered application can be used indefinitely (but a message will pop up periodically, stating that ST3 is not registered).

Homebrew


Missing package manager for OS X. To install, open the terminal and copy the following command to the terminal for installation:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" brew update brew doctor 


Add the following line to your .bash_profile or .zsh_profile
 export PATH="/usr/local/bin:$PATH" 


Install Node.js and Grunt


 brew install node npm install -g grunt-cli 


Install Mono


 brew install mono 


Install Yeoman


Yeoman - perhaps the most popular scaffolder of late. In fact, Yeoman itself is not just a scaffolder, but a whole set of tools that perfectly complement each other in the process of scaffolding and are harmoniously combined in the development process. Yeoman “stands on three pillars”, which set the tone for the workflow of modern developers: the Yo scaffolder, the Bower package manager and the Grunt task manager.

 npm install -g yo npm install -g generator-aspnet 


To start the Yeoman scaffolding type in the terminal
 yo aspnet 




Yoman generated a blank of our future application (by the way, this is already quite a working site).



Install utilities for ASP.NET vNext


 brew tap aspnet/k brew install kvm 


Add in .bash_profile line
 source kvm.sh 


Set up your new project in Sublime Text 3


Since this is your first ASP.NET project in ST3, you need to install a Kulture (ASP.NET vNext extension for ST3):


For C # to earn Intellisense, install OmniSharp
- Using Package Control, install the OmniSharp package (follow the instructions for setting up OmniSharp ).

Run your project





Note: in writing this article I relied on material from the blog MARIA NAGGAGA (Microsoft Tech Evangelist).

Source: https://habr.com/ru/post/243483/


All Articles