Command not found csc on Debian by Josh Sherman

Related Articles

I recently inherited a .NET application written in C#. I know little to nothing about any of the above, but I do know how to use web search and/or an AI chatbot to figure things out.

However, I installed Mono locally, as one does when trying to run .NET code on a Linux machine, in my case, a Debian installation.

here and there, mono Runs fine, but that’s for running fancy executables.

God csharp The command is also run, but it is an interactive C# REPL.

It seems the thing I wanted was cscC# compiler, so I can take the
.cs file I had and compiled it into an .exe which could then be executed with

Remember, I learned this from what I would consider a reputable source, the Mono Project documentation.

Of course, when I went to run it and was greeted with:

% csc
zsh: command not found: csc

Already pretty salty that I have to work with a .NET application, given that our entire existing stack is in Node.js, I went looking for another, because I wasn’t going to let it beat me.

Sure, I could dare to use mono Docker image, but I really wanted to run things locally before trying to Dockerize things.

So it turns out that in Debian the command is not cscIt mono-csc.

Why? No crazy idea. It would make a bit more sense if all commands were prefixed like that, then csharp was mono-csharp But that was not the case at all.

Mystery solved, with more mysteries to unravel when I try to run the app in its entirety on Linux, and not just on a single .cs file.

good things? want more?

Weekly emails about technology, development and sometimes sauerkraut.

100% Fresh, Grade A Content, Never Spam.


Popular Articles