✅ Adding class to .csproj file
Linux and command line user here.
Is there an easier way to add a class to a .csproj file other than manually opening it in an editor and typing it out? are there some CLI tools to make this easier? or am I just gonna have to make my own?
OS: Linux
Editor: Visual Studio Code
.NET Version: 7.0.1
8 Replies
What do you mean? What do want to add to the csproj file?
You can create some dotnet specific things using
dotnet new
Oh my god
No pox, you're giving me too much credit, I actually thought that
.cs
files needed to be added to .csproj
separately.
But apparently the reason why there is nothing about this online is because just create a .cs
file makes it automatically work you dont add classes csproj
I could've sworn you had to add
.cs
classes to .csproj
, was this always the case?afaik
Ohhh, I figured out the cause of my confusion, at work, we work in a multi project solution, which is why we need to add the project references, I genuinely don't know how I've managed to make the connection of adding
.csproj
equals adding .cs
Thanks peepsoh lol
np
$close
Use the
/close
command to mark a forum thread as answered