Useful tutorial:

How to Install Visual Studio Code on CentOS 8

Prerequisites

Login to the CentOS 8 system with sudo privileged account.

Install Mono on CentOS 8

First of all, install some required packages and import GPG key to your system. You need to add yumrepository provide by the official team. Run the following command to add Mono repository to your system based on CentOS 8 version. Once you added the repository, install Mono packages on your CentOS 8 system. The mono-devel package is used to compile code. The mono-complete package is used to install everything on the system. Press y and Enter to complete the Mono installation on CentOS 8.

Check Mono Version

Once the installation has finished on your system. Let’s check the installed Mono version using the following command. Output:

Run C# Example with Mono

As you have installed Mono on your CentOS 8 system. Create a sample c# program to run with Mono. Create a Welcome.cs file and edit in your favorite text editor. Add below value to file.

Save file and close it. Then compile the c# program with the c# compiler using below command. Once the compilation finished successfully, it will create a exe file in the local directory with the same name as script. In this case a Welcome.exe file is generated in my local directory. Set the exectue permission and then run the program You will see the output like below screenshot:

All done, You have successfully installed Mono on your CentOS 8 system. Next you may required to install Visual Studio Code on CentOS 8 Linux system.

How to Install Mono on CentOS 8   TecAdmin - 62