astral
How to Build Multiple Binaries from Dotnet New Console?
I have the following:
I move
Program.cs
to src/Program.cs
and it still seems to work. I replace src/Program.cs
with src/echo.cs
with the following:
This is note-box.csproj
:
I see there's the executable note-box
and it behaves like echo
when I pass args. When I add a second main
entry point, src/true.cs
:
It errors. The goal is to have echo
and true
be two different programs.
Another solution that I'm not sure if will work is if I just have one entry point:
src/note-box.cs
:
This would do something like ./bin/note-box echo
or ./bin/note-box true
. If this approach is better, I would want to make symlinks to note-box
and have the name of the link be what it calls. In C it's something like:
I'm not sure how to resolve link name of executable in a C# way.39 replies