fsprojects / ProjectScaffold

A prototypical .NET solution (file system layout and tooling), recommended for F# projects
http://fsprojects.github.io/ProjectScaffold
The Unlicense
515 stars 154 forks source link

Proposed updates to ProjectScaffold #325

Closed jackfoxy closed 6 years ago

jackfoxy commented 6 years ago

Proposed updates to ProjectScaffold

I have some changes in my personal fork I can submit to the master branch here. I'll propose a thumbs up/down vote on each.

I have no experience with dotnet templates, and so no opinion about whether this project is suitable to convert, or if any of my changes are compatible.

1) Dotnet SDK projects. I multi-target the main library project to net45;net47;netstandard2.0. And I have added a console project I multi-target to net47;netcoreapp2.0 Test project is targeted to net47

2) Drop NUnit and make the test project Expecto tests. Includes some simple/random FsCheck generators, (maybe not the best examples in the world.) (Ideally making NUnit or Expecto an option in the initialization would be nice, but that's more work than I am interested in doing.)

3) Additional console app using Argu lib. I also stubbed-out the common way I parse commands using Argu. In truth I threw together this generalized parsing in a hurry from some existing projects, so I don't guarantee all the parsing works perfectly out of the box, but it is close.

4) All solution files accessible from within solution IDE. Why open the solution in VS IDE and not have access to files like .gitignore, appveyor.yml, build.cmd, etc?

5) Latest FSharp.Formatting prerelease. If you haven't noticed, the release version of FSharp.Formatting has lots of problems.

6) My personalized prelude file in the library project. https://github.com/jackfoxy/ProjectScaffold/blob/master/src/FSharp.ProjectTemplate/Prelude.fs

jackfoxy commented 6 years ago

Dotnet SDK projects

thumbs up/down

jackfoxy commented 6 years ago

Drop NUnit and make the test project Expecto tests

thumbs up/down

jackfoxy commented 6 years ago

Additional console app using Argu lib

thumbs up/down

jackfoxy commented 6 years ago

All solution files accessible from within solution IDE

thumbs up/down

jackfoxy commented 6 years ago

Latest FSharp.Formatting prerelease

thumbs up/down

jackfoxy commented 6 years ago

My personalized prelude file in the library project

https://github.com/jackfoxy/ProjectScaffold/blob/master/src/FSharp.ProjectTemplate/Prelude.fs thumbs up/down

Krzysztof-Cieslak commented 6 years ago

If we went with SDK template road some of those decisions may be done by users, with parameters. In particular it would make sense for those ideas (from above list) - additional console app, type of test framework, custom prelude

jackfoxy commented 6 years ago

If someone wants to do the work to turn this project into a SDK template, I would accept the PR.

jackfoxy commented 6 years ago

I'm curious to hear the reason(s) for down-voting making all files available from within the solution?

jackfoxy commented 6 years ago

Here's what seems to be trending favorably. I'll try to get this in on the weekend, if the trends hold.

Dotnet SDK projects

Drop NUnit and make the test project Expecto tests

Additional console app using Argu lib

All solution files accessible from within solution IDE

Latest FSharp.Formatting prerelease

jackfoxy commented 6 years ago

I have pushed a beta branch https://github.com/fsprojects/ProjectScaffold/tree/betanetstandard for community testing with the following changes:

Dotnet SDK projects Drop NUnit and make the test project Expecto tests Additional console app using Argu lib All solution files accessible from within solution IDE Latest FSharp.Formatting prerelease

I also made a couple of changes to paket.dependencies:

jackfoxy commented 6 years ago

I will merge early in the workweek, pending feedback.

matthid commented 6 years ago

@jackfoxy I guess we should update fake as well to 5

jackfoxy commented 6 years ago

@matthid yes, that and dotnet cli template are good next steps I will open an issue for fake 5

jackfoxy commented 6 years ago

PR merged https://github.com/fsprojects/ProjectScaffold/pull/326