Our speckle-sharp monorepo had been gathering some tech debt for a while, when it started we never planned to have +100 projects!

Some changes have been made to ensure we can continue to work in a consistent manner and using the latest tooling.

What’s been merged into dev already

Single solution - multiple filters

Our monorepo consisted on one All.sln (hardly used except for big refactors), and a set of ConnectorXXX.sln files, one for each connector we develop. We also had a solution for Core, DUI and Objects

We’re going to move away from having multiple solutions in favour of a single solution and the use of solution filters. This will allow us to unify our configurations and build dependencies into one place, and ensure that we have a single source of truth on what projects exist on our repo.

Solution filters in MSBuild - MSBuild

*.props and *.targets files

Two new files have been added to the root of the repo: Directory.Build.props and Directory.Build.targets

These files are automatically imported by every project inside our repo, and hold all the duplicated tags that were originally spread across our csproj files.

The Directory.Build.props file is imported before any other content in your .csproj files, and contains things like company, authors, repo, copyright, license…👇🏼

Screenshot 2023-04-03 at 10.23.06.png

The Directory.Build.targets file is imported after any other content in your .csproj files, and contains 2 targets: