getsentry / sentry-dotnet

Sentry SDK for .NET
https://docs.sentry.io/platforms/dotnet
MIT License
579 stars 206 forks source link

Remove `before.Sentry.sln.targets` in favor of using `ValidateSolutionConfiguration` #1044

Open bruno-garcia opened 3 years ago

bruno-garcia commented 3 years ago

In order to restore git submodule before running the first build through dotnet build, ideally we'd hook into ValidateSolutionConfiguration. That wasn't possible (see https://github.com/dotnet/msbuild/issues/6452) so as a work around we added before.Sentry.sln.targets to the repo.

Once the fix ships on msbuild/.NET SDK, remove before.Sentry.sln.targets in favor of using ValidateSolutionConfiguration

vaind commented 9 months ago

Instead of relying on a solution-based configuration, which doesn't get triggered when you build individual projects, e.g. dotnet build samples/...., we could maybe use this: https://git-scm.com/docs/git-config#Documentation/git-config.txt-submodulerecurse (@jamescrosswell linked this a while back on Discord)