DEV Community

Calin Baenen
Calin Baenen

Posted on

What can I use to compile C# (CSharp)?

I wanna get in to CSharp since I know it's a bytecode language, like Java, but is (from what I've seen) faster.
So, how would I go about compiling some CSharp (basically what I want is the C# equiv to javac *.java; jar cfm *.class manifest.txt)?

##

Thanks!
Cheers!

Top comments (5)

Collapse
 
eelstork profile image
Tea

The other thing is, C# is available through either Visual Studio or .NET core. en.wikipedia.org/wiki/.NET_Core
And the equivalent of javac is the dot net CLI (command line interface)
docs.microsoft.com/en-us/dotnet/co...
So that's cross platform and overall easy to use, imho

Collapse
 
aileenr profile image
Aileen Rae

If you're looking to get started with learning C#, I recommend looking into .NET Core. This is the most modern software framework that lets you build apps in C#.

.NET Core is created by Microsoft, and their official documentation provides some really easy tutorials, which also tell you what you need to install to get started.

This tutorial walks you through creating a really simple console app that logs "Hello World" to the console. As you'll see when you follow the tutorial, you don't need to worry about compiling.

If you want to try something more complicated and build a whole website with a server + a database, this tutorial series walks you through the whole process.

Collapse
 
dijit profile image
Jan Harasym • Edited

You use the 'dotnet' runtime; there's no intermediate step in 'packing' like your example, you just run dotnet build <path_to_csproj> and you should have a binary output.

Collapse
 
baenencalin profile image
Calin Baenen

What is .NET (runtime)? I've heard of it, and seen it mentioned, but I've never really understood it.

Collapse
 
eelstork profile image
Tea

Part of the answer to your qs is here
en.wikipedia.org/wiki/Common_Inter...