C# in linux environment

2019-04-26 18:45发布

问题:

I am currently working in C/C++ in a Unix environment and am new to Linux environments. I would like to learn about the Linux OS and learn C# as the next level of programming language for my career.

I decided to put Ubuntu Linux on my laptop. But I am not sure whether we can write, compile and run C# programs in Linux environments or not.

The only IDE I know for C# is MS Visual Studio. Is there are any possible way to work in C# in a Linux environment?

If I have no other option, I'll have both operating systems on my laptop - Vista to learn C# and Linux for the other OS.

回答1:

Learn Mono.

The Mono Project is an open development initiative sponsored by Novell to develop an open source, UNIX version of the Microsoft .NET development platform. Its objective is to enable UNIX developers to build and deploy cross-platform .NET Applications. The project implements various technologies developed by Microsoft that have now been submitted to the ECMA for standardization.

You can use the MonoDevelop IDE.

MonoDevelop is a free GNOME IDE primarily designed for C# and other .NET languages.



回答2:

Mono is an open source .NET compiler, runtime and library.
Monodevelop is an open source C# IDE, primarily intended for linux development. It includes a GUI designer.



回答3:

You can also use wine, which is a free implementation of Windows' API. For this : sudo apt-get install wine then you'll be able to run Microsoft applications and do [almost] everything you like.

EDIT : My mistake, Visual Studio is not functional :-(



回答4:

A Vista virtual machine in seamless mode running Visual Studio? Then it will appear to integrate into your desktop like any other app, but you'll have the benefit of running the real MS stuff (with C#, having real MS is still a benefit rather than a liability).