For C#/VB.NET, keep solution and project file in same directory
Even though Visual Studio by default creates the .sln file in the root directory and creates a .csproj/.vbproj file in a subdirectory with all the project files, I don't think this is really necessary.
For example, Amazing (C#) has only four files without a subdirectory; while Acey Ducey (VB.NET) has the unneeded subfolder.
Sure! If we can normalize on the simpler method, and it still works with Visual Studio, I'm all for it! Feel free to check in a normalization of all csharp (and vbnet) folders!
@zspitz if you'd like to take this on it would be quite welcome!
OK. I'll work it out, as part of generating a standard template for the C#/VB versions.
Thanks @zspitz, much appreciated!
I'm rethinking this. When there are multiple projects, then each project should be in a separate folder. There are currently four ports that have multiple projects, for one of two reasons:
- A separate test project, as in Craps (C#), Train (C#) and War (C#)
- An abstraction of console output, as in BombsAway (C#)
Not sure about the second -- unless we're going to create some shared abstraction of output usable by all the programs, I think having it in each one is just added noise. But I think having test projects is certainly a valid reason for multiple projects.
Moving an existing port from a "project-in-same-folder-as-solution" to "project-in-subfolder" requires a bit of work:
- opening the solution
- removing the project from within the solution
- moving the project files into a subfolder --
.csproj/.vbprojand all the code files - reattaching the
.csproj/.vbprojfile from its new location
This is a strong argument for having the project files in a subfolder from the beginning, especially since this is how Visual Studio constructs projects by default.
This is implemented via #520.