Build updates for compatibility #2044
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
These were issues I had to fix to get Serilog building/testing on a Mac as part of the benchmarking for #1944.
.vscode
folder isn't a per-user setting the way.vs
is..vscode
is how you provide a default build/test command for VS Code folks. I added that support so things like "Open Repo in VS Code" or other contributors can get going a little faster.Push-Location
at the start but neverPop-Location
, so you'd end up with a stack of history entries. Added a try/finally so at the end - failure or success - it will still pop back to where you were.feature/xyz
with slashes. Added a fix for that so it'll replace slash with dash.SourceContextMatchBenchmark
fixture caused some problems due to the targeting specifically ofnetcoreapp2.1
andnetcoreapp3.1
. During the execution of the benchmarks, BenchmarkDotNet auto-generates an assembly that targets these frameworks so they can be run. This auto-generated assembly hasTreatWarningsAsErrors
turned on. In .NET 8, you get a NuGet warning when you try to targetnetcoreapp2.1
becauseMicrosoft.NETCore.App
v2.1.0 has known security issues. All of this adds up to the auto-generated assembly not compiling and the benchmarks not running. Even if you get thenetcoreapp3.1
building, you still get issues becauseSystem.Diagnostics.DiagnosticSource
writes warnings about how it hasn't been tested and isn't supported againstnetcoreapp3.1
. The fix for this is to:SourceContextMatchBenchmark
so you don't get the security warnings.I'm fine rolling any or all of this back, but this is what it took for me, on a Mac, to get this all working smoothly. Hopefully it can help other devs/contributors to get on board faster.