Getting Started With Mono

[mono logo]

Mono has just hit 1.0. It is now time for me to abandon Java and start developing in c# instead. Let's get started:

## Lines added to /etc/yum.conf
## visit
## for the correct url for your distro and version.
name=Ximian Mono

After updating /etc/yum.conf, I installed everything mono, willy-nilly.

$ sudo yum install mono*

Now we play with mcs, the mono compiler. Here is Hello World:

/* ~/code/c-sharp/Hello.cs */
   Hello World in C Sharp
using System;
class  Hello {
    static void Main() {
	Console.Write("hello world\n");

Compile and and run:

$ mcs Hello.cs
Compilation succeeded
$ ls
Hello.cs  Hello.exe
$ mono Hello.exe
hello world


$ monodoc &