Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move dotnet/format to dotnet/sdk #38857

Merged
merged 3,323 commits into from
Mar 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
3323 commits
Select commit Hold shift + click to select a range
fc5cc04
Include external access layer for Razor
sharwell Oct 23, 2023
801d245
Merge pull request #1990 from dotnet/merges/release/8.x-to-main
dotnet-bot Oct 23, 2023
84eb2b7
Merge pull request #1989 from sharwell/ea-layer
sharwell Oct 23, 2023
2c6f36d
Merge remote-tracking branch 'dotnet/release/7.x' into merges/release…
sharwell Oct 23, 2023
580368d
Merge pull request #1991 from dotnet/merges/release/7.x-to-release/8.x
sharwell Oct 23, 2023
db7e0d5
[release/8.x] Update dependencies from dotnet/roslyn (#1968)
dotnet-maestro[bot] Oct 23, 2023
7096dd8
Merge pull request #1992 from dotnet/merges/release/8.x-to-main
dotnet-bot Oct 23, 2023
5f8c76c
Migrate official build pipeline to dnceng (#1988)
jjonescz Oct 24, 2023
cecb88a
Merge branch 'release/8.x' into darc-release/8.x-c23d961a-f29c-4127-b…
jjonescz Oct 24, 2023
c519d26
Migrate official build pipeline to dnceng
jjonescz Oct 23, 2023
79b771c
Update VS version used for signed builds
jjonescz Oct 20, 2023
ecc2f27
Disable signing validation
jjonescz Oct 24, 2023
fd1f33b
Merge pull request #1967 from dotnet/darc-release/8.x-c23d961a-f29c-4…
jjonescz Oct 24, 2023
5190325
Merge pull request #1970 from dotnet/darc-main-659d666e-101e-4dad-85f…
jjonescz Oct 24, 2023
4b74199
Merge pull request #1927 from dotnet/darc-release/7.x-98c6a3f6-f7e9-4…
jjonescz Oct 24, 2023
de93580
[main] Update dependencies from dotnet/roslyn (#1924)
dotnet-maestro[bot] Oct 24, 2023
2d8acfd
[release/8.x] Update dependencies from dotnet/runtime (#1987)
dotnet-maestro[bot] Oct 24, 2023
3c3c81d
Merge branch 'release/8.x' into merges/release/7.x-to-release/8.x
ViktorHofer Oct 24, 2023
aadaa16
Merge pull request #1994 from dotnet/merges/release/7.x-to-release/8.x
ViktorHofer Oct 24, 2023
febf17c
Merge branch 'main' into merges/release/8.x-to-main
ViktorHofer Oct 24, 2023
2a374a5
Merge pull request #1995 from dotnet/merges/release/8.x-to-main
dotnet-bot Oct 24, 2023
c18a4af
[main] Update dependencies from dotnet/arcade (#1973)
dotnet-maestro[bot] Oct 24, 2023
57d13ca
[main] Update dependencies from dotnet/runtime (#1969)
dotnet-maestro[bot] Oct 24, 2023
eddf4f3
Merge branch 'main' into merges/release/8.x-to-main
ViktorHofer Oct 24, 2023
a99dd51
Update NuGet.config
ViktorHofer Oct 24, 2023
03e4fb2
Update Version.Details.xml
ViktorHofer Oct 24, 2023
8a707d9
Merge pull request #1996 from dotnet/merges/release/8.x-to-main
ViktorHofer Oct 24, 2023
f5f24f3
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Oct 25, 2023
5bb432b
Merged PR 34796: [internal/release/8.x] Update dependencies from dnce…
dotnet-bot Oct 25, 2023
592b10a
Merged PR 34804: [internal/release/8.x] Update dependencies from dnce…
dotnet-bot Oct 25, 2023
52642a8
Merged PR 34837: Set up private feeds before building
mmitche Oct 26, 2023
725ae8c
Wait for process redirection to start before calling WaitForExit
mslukebo Oct 26, 2023
706bcdf
Dispose of MRE on cancel path
mslukebo Oct 26, 2023
1e3f9b7
Remove lock
mslukebo Oct 26, 2023
649db1d
[main] Update dependencies from dotnet/arcade (#1999)
dotnet-maestro[bot] Oct 27, 2023
3646b1c
[main] Update dependencies from dotnet/arcade (#2001)
dotnet-maestro[bot] Oct 27, 2023
7875aea
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Oct 28, 2023
553764f
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Oct 28, 2023
af05872
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Oct 29, 2023
dc9fa05
Update dependencies from https://dev.azure.com/dnceng/internal/_git/d…
dotnet-bot Oct 31, 2023
d71cade
Update dependencies from https://github.com/dotnet/runtime build 2023…
dotnet-maestro[bot] Oct 31, 2023
78c3592
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Oct 31, 2023
7985706
Update dependencies from https://github.com/dotnet/roslyn build 20231…
dotnet-maestro[bot] Oct 31, 2023
aa7c923
Merge in 'release/8.x' changes
dotnet-bot Oct 31, 2023
3bef1e4
Merged PR 34921: [internal/release/8.x] Update dependencies from dnce…
dotnet-bot Oct 31, 2023
dc4fe25
Merge branch 'main' into merges/release/8.x-to-main
ViktorHofer Oct 31, 2023
1e942c1
Merge pull request #2010 from dotnet/merges/release/8.x-to-main
ViktorHofer Oct 31, 2023
ae704a7
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Oct 31, 2023
2651752
Merged PR 34959: [internal/release/8.x] Update dependencies from dnce…
dotnet-bot Oct 31, 2023
65966ca
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 1, 2023
9d4baf6
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 2, 2023
ebac601
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 3, 2023
d5bd7ef
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 4, 2023
db8c5ca
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 7, 2023
448505c
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 8, 2023
aa43f67
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 9, 2023
b246fa4
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 10, 2023
2a762f0
Merge pull request #2000 from mslukebo/user/lukebo/processWait
sharwell Nov 10, 2023
40777d5
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 11, 2023
ac898ed
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 14, 2023
ae20800
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 15, 2023
cb4c453
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 16, 2023
4e187bc
Rmove unneeded sources from NuGet.config
mmitche Nov 16, 2023
28925c0
Merge pull request #2031 from mmitche/merge-from-rtm
mmitche Nov 16, 2023
10e0a79
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 18, 2023
e730bad
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 21, 2023
f0e966d
Reverts the https://github.com/dotnet/format/pull/1983 pull request t…
MiYanni Nov 23, 2023
919e37f
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 23, 2023
0bdb5f3
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 28, 2023
7058f2a
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 29, 2023
46077f5
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Nov 30, 2023
c61caa3
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 1, 2023
bfe4cc1
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 2, 2023
fd32df2
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 5, 2023
ba3af10
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 6, 2023
2ea1f44
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 7, 2023
71257e1
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 8, 2023
e09a44f
Remove Microsoft.SourceBuild.Intermediate from prebuilt baseline (#2047)
ellahathaway Dec 8, 2023
947156d
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 12, 2023
156f6ee
Update Version.Details.xml (#2048)
ViktorHofer Dec 12, 2023
3a3bfe1
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 13, 2023
9484e6c
Update dependencies from https://github.com/dotnet/arcade build 20231…
dotnet-maestro[bot] Dec 14, 2023
5c9a041
Remove GitHub automation requiring reviews when the SDK version changes
jeffhandley Dec 15, 2023
f198eb6
Merge pull request #2053 from jeffhandley/jeffhandley/remove-sdkversi…
arunchndr Dec 15, 2023
4425369
[main] Update dependencies from dotnet/arcade (#2054)
dotnet-maestro[bot] Dec 18, 2023
ec8dd5d
Merge branch 'main' into merges/release/8.x-to-main
mmitche Dec 18, 2023
5fb8ea4
Merge pull request #2032 from dotnet/merges/release/8.x-to-main
dotnet-bot Dec 18, 2023
2c2d58c
Rename perf project to Arcade standard suffix 'PerformanceTests' (#2055)
ViktorHofer Dec 18, 2023
f58bc29
[main] Update dependencies from dotnet/roslyn (#2005)
dotnet-maestro[bot] Jan 9, 2024
c366f61
[main] Update dependencies from dotnet/arcade (#2056)
dotnet-maestro[bot] Jan 9, 2024
98457c8
[main] Update dependencies from dotnet/source-build-externals (#2016)
dotnet-maestro[bot] Jan 9, 2024
84b3d10
[main] Update dependencies from dotnet/runtime (#2015)
dotnet-maestro[bot] Jan 9, 2024
a58eac3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 10, 2024
eda92c2
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 11, 2024
4d2f4c5
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 13, 2024
0d1397d
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 16, 2024
5ee665c
[main] Update dependencies from dotnet/command-line-api (#2059)
dotnet-maestro[bot] Jan 16, 2024
86e010f
Update dependencies from https://github.com/dotnet/source-build-exter…
dotnet-maestro[bot] Jan 16, 2024
2e99b18
Update dependencies from https://github.com/dotnet/runtime build 2024…
dotnet-maestro[bot] Jan 16, 2024
6cc40cb
[main] Update dependencies from dotnet/roslyn (#2065)
dotnet-maestro[bot] Jan 16, 2024
db7b254
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 17, 2024
15aa579
[main] Update dependencies from dotnet/arcade (#2070)
dotnet-maestro[bot] Jan 17, 2024
0c424b6
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 18, 2024
2036958
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 19, 2024
ed49f9c
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 20, 2024
a9b7ba7
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 23, 2024
af231fa
Flow live versions of Microsoft.Build and Microsoft.Build.Tasks.Core …
ellahathaway Jan 23, 2024
62ad866
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 24, 2024
ac63bf9
[main] Update dependencies from dotnet/arcade (#2081)
dotnet-maestro[bot] Jan 26, 2024
32d58a6
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 27, 2024
93f512a
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 30, 2024
7951dd1
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Jan 31, 2024
e8f2449
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Feb 1, 2024
1710ae3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Feb 2, 2024
d102001
Move SB metadata to intermediates (#2090)
ellahathaway Feb 2, 2024
6fe8c25
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Feb 3, 2024
d73ee58
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Feb 6, 2024
1733da0
[main] Update dependencies from dotnet/source-build-externals (#2078)
dotnet-maestro[bot] Feb 7, 2024
1902d8c
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Feb 7, 2024
4ffa2f1
[release/8.x] Update dependencies from dotnet/roslyn (#2017)
dotnet-maestro[bot] Feb 7, 2024
1716d9e
[main] Update dependencies from dotnet/command-line-api (#2073)
dotnet-maestro[bot] Feb 7, 2024
fcce27f
[main] Update dependencies from dotnet/runtime (#2077)
dotnet-maestro[bot] Feb 7, 2024
4480923
Clarify include/exclude parameter input format in readme (#2099)
riverar Feb 8, 2024
cbef833
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 9, 2024
49b4186
Merge branch 'release/8.x' into merges/release/8.x-to-main
jjonescz Feb 9, 2024
e07ea47
Merge pull request #2096 from dotnet/merges/release/8.x-to-main
dotnet-bot Feb 9, 2024
d8aa880
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 9, 2024
cc2d68b
Remove dependancy on EA.RazorCompiler
JoeRobich Feb 9, 2024
2930a4f
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 10, 2024
578e193
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 11, 2024
7943195
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 12, 2024
8a1ad5c
Update dependencies from https://github.com/dotnet/source-build-exter…
dotnet-maestro[bot] Feb 12, 2024
10d9ef7
Upgrade msbuild version
Cosifne Feb 12, 2024
055aedb
Upgrade source build version
Cosifne Feb 12, 2024
ed0b618
Upgrade version in Version.Details.xml
Cosifne Feb 12, 2024
124d3ab
Merge pull request #2102 from dotnet/darc-main-30682688-22d5-4b2a-9fd…
Cosifne Feb 12, 2024
09e16d4
Merge remote-tracking branch 'upstream/main' into darc-main-6216b94f-…
Cosifne Feb 12, 2024
7084790
Update baseline
Cosifne Feb 12, 2024
7298c3b
Add versions in Version.Details.xml
Cosifne Feb 12, 2024
3d40cb0
Add project url
Cosifne Feb 12, 2024
d4a428c
Remove Microsoft.VisualStudio.Setup.Configuration.Interop
Cosifne Feb 12, 2024
fd554ed
Merge pull request #2100 from dotnet/darc-main-6216b94f-a181-4ea1-9b0…
Cosifne Feb 12, 2024
00c9d55
Update dependencies from https://github.com/dotnet/runtime build 2024…
dotnet-maestro[bot] Feb 13, 2024
39b14d6
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 13, 2024
23065d6
Merge pull request #2104 from dotnet/darc-main-1f81f14c-fea6-4c71-85d…
Cosifne Feb 13, 2024
17f057b
Update dependencies from https://github.com/dotnet/command-line-api b…
dotnet-maestro[bot] Feb 14, 2024
42462b3
Update dependencies from https://github.com/dotnet/arcade build 20240…
dotnet-maestro[bot] Feb 14, 2024
2001686
Fix CLI sln or proj argument name and description
dviererbe Feb 14, 2024
30b66f0
Merge pull request #2108 from dviererbe/fix-sln-or-proj-argument-name…
JoeRobich Feb 15, 2024
82edc54
Update dependencies from https://github.com/dotnet/roslyn build 20240…
dotnet-maestro[bot] Feb 15, 2024
39d0f6e
Move documatations
Cosifne Feb 15, 2024
9a1b718
Move perf tests to test folder
Cosifne Feb 15, 2024
b142675
Move unit tests
Cosifne Feb 15, 2024
7b4f54b
Move src to src\dotnet-format
Cosifne Feb 15, 2024
108e41a
Fix perf.ps1
Cosifne Feb 15, 2024
92dd288
Move verifier and integration test to eng/dotnet-format
Cosifne Feb 15, 2024
c3a6bd4
Merge remote-tracking branch 'origin-format/dev/shech/mergeIntoSDK' i…
Cosifne Feb 16, 2024
6e2a337
Address more conflicts
Cosifne Feb 16, 2024
86e2b37
Move and create solution filter file
Cosifne Feb 16, 2024
57a434f
Update reference
Cosifne Feb 16, 2024
a66faeb
Add to sln file
Cosifne Feb 16, 2024
6c1cd9b
Update filter
Cosifne Feb 16, 2024
d0788f6
Put performance tests into a different folder because test folder has…
Cosifne Feb 17, 2024
d92bbf2
Only include the original test file
Cosifne Feb 17, 2024
7dd7fc9
Change output type to exe so that xUnit console could be used
Cosifne Feb 17, 2024
216849d
Update the publish target to directly copy from output folder
Cosifne Feb 17, 2024
72cccc2
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 17, 2024
ac14992
Address unmerged conflicts
Cosifne Feb 17, 2024
76731b5
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 20, 2024
178edae
More conflicts addressed
Cosifne Feb 20, 2024
f32c7a7
Remove duplicate signing
Cosifne Feb 20, 2024
79f1120
remove duplicate in eng/Version.Details.xml
Cosifne Feb 20, 2024
f8037a4
Remove code of conduct
Cosifne Feb 22, 2024
4372bfc
Move change log to dotnet format folder
Cosifne Feb 22, 2024
f8cb8ff
Remove .github/CODEOWNER and .github/fabricBot.json
Cosifne Feb 22, 2024
095555e
Remove .config/tsaoptions.json
Cosifne Feb 22, 2024
c2bdfae
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 22, 2024
44b9292
Move test-plan and CHANGELOG to documentation
Cosifne Feb 22, 2024
3d1cb61
Move Perf.cmd to eng/dotnet-format/Perf.cmd
Cosifne Feb 22, 2024
4445d29
Remove ominishaprp.json
Cosifne Feb 22, 2024
67356de
Move validate.rsp to eng/dotnet-format/validate.rsp
Cosifne Feb 22, 2024
a6edf40
Add test to UnitTests.proj
Cosifne Feb 23, 2024
c010cf5
Move azure-pipeline.*yml under eng/dotnet-format/
Cosifne Feb 23, 2024
141b9e6
Remove .vscode/*
Cosifne Feb 23, 2024
28420f0
Remove .devcontainer
Cosifne Feb 23, 2024
aa79eaa
Delete the azure-pipeline files, put the test job into one yml
Cosifne Feb 23, 2024
0d56762
Remove .pre-commit-hooks.yaml
Cosifne Feb 23, 2024
101bf6a
Remove Restore.cmd
Cosifne Feb 23, 2024
98ec58c
Remove Build.cmd
Cosifne Feb 23, 2024
b5e4470
Remove Test.cmd
Cosifne Feb 23, 2024
eb86be7
Fix the path
Cosifne Feb 23, 2024
56d41f0
Move test assets file to src/Asserts
Cosifne Feb 23, 2024
d99e30e
Include the test assets in test/UnitTests.proj
Cosifne Feb 23, 2024
cbfbfa0
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 23, 2024
3c5e6ca
Do not copy the test assets to output
Cosifne Feb 23, 2024
10a3ab6
Exclude dotnet-format.TestProjects from build
Cosifne Feb 24, 2024
887a4c8
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 24, 2024
f5d17b2
Fix build
Cosifne Feb 24, 2024
b3af336
Bring System.CommandLineRendering back
Cosifne Feb 24, 2024
1f5a671
Add System.CommandLine.Rendering to source build baseline
Cosifne Feb 24, 2024
5892829
Fix path of NuGet.config issue on Helix
Cosifne Feb 26, 2024
dc41c29
Use TestContext to locate TestAsserts
Cosifne Feb 26, 2024
134c7a3
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 26, 2024
d88c65d
Find test assert directory from two places
Cosifne Feb 27, 2024
9b6efdd
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 27, 2024
dd0c714
Add the missing assets
Cosifne Feb 27, 2024
787379f
Rename
Cosifne Feb 28, 2024
997d9b9
Explicitly add .editorconfig
Cosifne Feb 28, 2024
8881805
Fix perf.ps1
Cosifne Feb 28, 2024
85e83d2
Link dotnet format integration
Cosifne Feb 28, 2024
1b2f40a
Chnage \ to /
Cosifne Feb 28, 2024
947f099
Add code owners
Cosifne Feb 28, 2024
82f325d
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 28, 2024
3f5d3f7
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Feb 29, 2024
6f4599b
Reset .gitattributes
Cosifne Feb 29, 2024
9d1292d
Remove benchmark
Cosifne Feb 29, 2024
bb64e43
Remove dotnet-format in Directory.Packages.props
Cosifne Feb 29, 2024
5bf7bac
Remove benchmarkdotnet from Direcotry.Pacakge.props
Cosifne Feb 29, 2024
8997f9f
Remove Changelog.md
Cosifne Feb 29, 2024
da74315
Remove perf.cmd and perf.ps1
Cosifne Feb 29, 2024
2f278ba
Add NoLogo back
Cosifne Feb 29, 2024
d5e29e6
Use repo root
Cosifne Feb 29, 2024
60b51a7
Change publish directory
Cosifne Feb 29, 2024
2c517ad
Add NoLogo back in build.cmd
Cosifne Mar 1, 2024
8615b80
Remove dotnet-format from Version.details
Cosifne Mar 1, 2024
2342874
Use lower case in the name of build.ps1
Cosifne Mar 1, 2024
1bac7f1
Remove BCL from version.details
Cosifne Mar 1, 2024
2f966df
Increase timeout
Cosifne Mar 1, 2024
0b1cbb6
Increase time limit
Cosifne Mar 1, 2024
5b9c607
Source the dogfood.sh before test
Cosifne Mar 1, 2024
d28eced
Build before format
Cosifne Mar 1, 2024
b076b32
Try windows image
Cosifne Mar 1, 2024
97540f4
Correct scirpt
Cosifne Mar 4, 2024
1e032e9
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Mar 4, 2024
69d7c19
Remove accidental added char
Cosifne Mar 4, 2024
7d65caa
Try fix the format check
Cosifne Mar 4, 2024
076f52d
Remove Intermediate.format
Cosifne Mar 4, 2024
3ad5f39
Pipe the script
Cosifne Mar 4, 2024
bbbf57b
Restore test/Directory.Build.targets
Cosifne Mar 7, 2024
eb8e6c2
Add comment
Cosifne Mar 7, 2024
3e70a96
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Mar 7, 2024
2364425
Sort and remove usings for all the dotnet/format code
Cosifne Mar 7, 2024
67ab69a
Remove test-plan
Cosifne Mar 8, 2024
6797e2e
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Mar 8, 2024
636ba11
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Mar 12, 2024
86c6af4
Do not copy dotnet-format to output
Cosifne Mar 14, 2024
8704b61
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Mar 14, 2024
50dfaa8
Remove assemblyResolver as it's no longer used
Cosifne Mar 18, 2024
fb74021
Use pattern to find dotnet-format dlls
Cosifne Mar 18, 2024
735809a
Merge remote-tracking branch 'upstream/main' into dev/shech/mergeFormat
Cosifne Mar 18, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .vsts-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ stages:
_Test: -test

- template: /eng/template-engine.yml
- template: /eng/dotnet-format/dotnet-format-integration.yml

- ${{ if and(ne(variables['System.TeamProject'], 'public'), notin(variables['Build.Reason'], 'PullRequest')) }}:
- template: /eng/common/templates/job/publish-build-assets.yml
Expand Down
4 changes: 4 additions & 0 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -92,3 +92,7 @@
/test/containerize.UnitTests @dotnet/sdk-container-builds-maintainers
/test/Microsoft.NET.Build.Containers.IntegrationTests @dotnet/sdk-container-builds-maintainers
/test/Microsoft.NET.Build.Containers.UnitTests @dotnet/sdk-container-builds-maintainers

# dotnet-format
/src/BuiltInTools/dotnet-format @dotnet/roslyn-ide
/test/dotnet-format.Tests @dotnet/roslyn-ide
20 changes: 17 additions & 3 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
@@ -1,27 +1,36 @@
<Project>
<Import Project="$(RepositoryEngineeringDir)\dependabot\Packages.props" Condition="'$(RepositoryEngineeringDir)' != ''"/>
<PropertyGroup>
<!-- Using multiple feeds isn't supported by Maestro: https://github.com/dotnet/arcade/issues/14155. -->
<NoWarn>$(NoWarn);NU1507</NoWarn>
</PropertyGroup>

<ItemGroup>
<PackageVersion Include="dotnet-format" Version="$(DotnetFormatVersion)" />
<PackageVersion Include="FluentAssertions" Version="$(FluentAssertionsVersion)" />
<PackageVersion Include="FluentAssertions.Json" Version="$(FluentAssertionsJsonVersion)" />
<PackageVersion Include="Microsoft.ApplicationInsights" Version="$(MicrosoftApplicationInsightsPackageVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.DeveloperCertificates.XPlat" Version="$(MicrosoftAspNetCoreDeveloperCertificatesXPlatPackageVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.Mvc.Razor.Extensions.Tooling.Internal" Version="$(MicrosoftAspNetCoreMvcRazorExtensionsToolingInternalPackageVersion)" />
<PackageVersion Include="Microsoft.AspNetCore.TestHost" Version="$(MicrosoftAspNetCoreTestHostPackageVersion)" />
<PackageVersion Include="Microsoft.Bcl.AsyncInterfaces" Version="$(MicrosoftNETCoreAppRefPackageVersion)"/>
<PackageVersion Include="Microsoft.Build.Locator" Version="$(MicrosoftBuildLocatorPackageVersion)" />
<PackageVersion Include="Microsoft.Build.NuGetSdkResolver" Version="$(MicrosoftBuildNuGetSdkResolverPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis" Version="$(MicrosoftCodeAnalysisPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.Analyzer.Testing" Version="$(MicrosoftCodeAnalysisAnalyzerTestingVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp" Version="$(MicrosoftCodeAnalysisCSharpPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.CodeStyle" Version="$(MicrosoftNetCompilersToolsetPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.Features" Version="$(MicrosoftCodeAnalysisCSharpFeaturesPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.Features" Version="$(MicrosoftCodeAnalysisCSharpPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.CSharp.Workspaces" Version="$(MicrosoftCodeAnalysisCSharpWorkspacesPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.Features" Version="$(MicrosoftCodeAnalysisPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="$(MicrosoftCodeAnalysisNetAnalyzersVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.PublicApiAnalyzers" Version="$(MicrosoftCodeAnalysisPublicApiAnalyzersVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.Razor.Tooling.Internal" Version="$(MicrosoftCodeAnalysisRazorToolingInternalVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.VisualBasic" Version="$(MicrosoftCodeAnalysisPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.VisualBasic.CodeStyle" Version="$(MicrosoftNetCompilersToolsetPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.VisualBasic.Features" Version="$(MicrosoftCodeAnalysisPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.VisualBasic.Workspaces" Version="$(MicrosoftCodeAnalysisPackageVersion)" />
<PackageVersion Include="Microsoft.CodeAnalysis.Workspaces.MSBuild" Version="$(MicrosoftCodeAnalysisWorkspacesMSBuildPackageVersion)" />
<PackageVersion Include="Microsoft.Css.Parser" Version="$(MicrosoftCssParserVersion)" />
<PackageVersion Include="Microsoft.DiaSymReader" Version="$(MicrosoftDiaSymReaderVersion)" />
<PackageVersion Include="Microsoft.Deployment.DotNet.Releases" Version="$(MicrosoftDeploymentDotNetReleasesVersion)" />
<PackageVersion Include="Microsoft.DotNet.Installer.Windows.Security.TestData" Version="$(MicrosoftDotNetInstallerWindowsSecurityTestDataPackageVersion)" />
<PackageVersion Include="Microsoft.DotNet.XUnitExtensions" Version="$(MicrosoftDotNetXUnitExtensionsVersion)" />
Expand All @@ -45,6 +54,8 @@
<PackageVersion Include="Microsoft.TemplateSearch.Common" Version="$(MicrosoftTemplateSearchCommonPackageVersion)" />
<PackageVersion Include="Microsoft.TestPlatform.Build" Version="$(MicrosoftTestPlatformBuildPackageVersion)" />
<PackageVersion Include="Microsoft.TestPlatform.CLI" Version="$(MicrosoftTestPlatformCLIPackageVersion)" />
<PackageVersion Include="Microsoft.VisualBasic" Version="$(MicrosoftVisualBasicVersion)" />
<PackageVersion Include="Microsoft.VisualStudio.Composition" Version="17.4.16" />
<PackageVersion Include="Microsoft.VisualStudio.Setup.Configuration.Interop" Version="$(MicrosoftVisualStudioSetupConfigurationInteropVersion)" />
<PackageVersion Include="Microsoft.Web.Deployment" Version="$(WebDeploymentPackageVersion)" />
<PackageVersion Include="Microsoft.Web.Xdt" Version="$(MicrosoftWebXdtPackageVersion)" />
Expand Down Expand Up @@ -74,6 +85,7 @@
<PackageVersion Include="System.CodeDom" Version="$(SystemCodeDomPackageVersion)" />
<PackageVersion Include="System.Collections.Specialized" Version="$(SystemCollectionsSpecializedPackageVersion)" />
<PackageVersion Include="System.CommandLine" Version="$(SystemCommandLineVersion)" />
<PackageVersion Include="System.CommandLine.Rendering" Version="$(SystemCommandLineRenderingVersion)" />
<PackageVersion Include="System.ComponentModel.TypeConverter" Version="4.3.0" />
<PackageVersion Include="System.Composition.AttributedModel" Version="$(MicrosoftNETCoreAppRefPackageVersion)"/>
<PackageVersion Include="System.Composition.Convention" Version="$(MicrosoftNETCoreAppRefPackageVersion)"/>
Expand Down Expand Up @@ -111,6 +123,7 @@
<PackageVersion Include="Microsoft.Build.Framework" Version="$(MicrosoftBuildVersion)" />
<!-- Localization is the same between source-only and regular modes. Always taken from latest. Duplicated between the itemgroups for clarity. -->
<PackageVersion Include="Microsoft.Build.Localization" Version="$(MicrosoftBuildLocalizationVersion)" />
<PackageVersion Include="Microsoft.Build.Locator" Version="$(MicrosoftBuildLocatorPackageVersion)" />
<PackageVersion Include="Microsoft.Build.Runtime" Version="$(MicrosoftBuildVersion)" />
<PackageVersion Include="Microsoft.Build.Tasks.Core" Version="$(MicrosoftBuildVersion)" />
<PackageVersion Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildVersion)" />
Expand All @@ -121,6 +134,7 @@
<PackageVersion Include="Microsoft.Build.Framework" Version="$(MicrosoftBuildMinimumVersion)" />
<!-- Localization is the same between source-only and regular modes. Always taken from latest. Duplicated between the itemgroups for clarity. -->
<PackageVersion Include="Microsoft.Build.Localization" Version="$(MicrosoftBuildLocalizationVersion)" />
<PackageVersion Include="Microsoft.Build.Locator" Version="$(MicrosoftBuildLocatorPackageVersion)" />
<PackageVersion Include="Microsoft.Build.Runtime" Version="$(MicrosoftBuildMinimumVersion)" />
<PackageVersion Include="Microsoft.Build.Tasks.Core" Version="$(MicrosoftBuildMinimumVersion)" />
<PackageVersion Include="Microsoft.Build.Utilities.Core" Version="$(MicrosoftBuildMinimumVersion)" />
Expand Down
11 changes: 11 additions & 0 deletions THIRD-PARTY-NOTICES.TXT
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
.NET Core uses third-party libraries or other resources that may be
distributed under licenses different than the .NET Core software.

In the event that we accidentally failed to list a required notice, please
bring it to our attention. Post an issue or email us:

[email protected]

The attached notices are provided for information only.

No notices are provided at this time.
2 changes: 1 addition & 1 deletion build.cmd
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
@echo off
powershell -NoLogo -NoProfile -ExecutionPolicy ByPass -Command "& """%~dp0eng\common\build.ps1""" -build -restore %*"
powershell -NoLogo -ExecutionPolicy ByPass -NoProfile -command "& """%~dp0eng\common\build.ps1""" -restore -build -msbuildEngine dotnet %*"
exit /b %ErrorLevel%
39 changes: 39 additions & 0 deletions documentation/format/docs/3rd-party-analyzers.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# 3rd Party Analyzers
Copy link
Member Author

@Cosifne Cosifne Feb 23, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All the docs of dotnet format are moved here.


## How to add analyzers to a project

3rd party analyzers are discovered from the `<PackageReferences>` specified in the workspace project files.

*Example:*

Add the StyleCop analyzer package to a simple console project file.

```diff
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
</PropertyGroup>

+ <ItemGroup>
+ <PackageReference Include="StyleCop.Analyzers" Version="1.1.118" />
+ </ItemGroup>

</Project>
```

## How to configure analyzer severity

The options specified in .editorconfig files are recognized by the pattern `dotnet_diagnostic.<diagnostic-id>.severity = <value>`. `<diagnostic-id>` represents the diagnostic ID matched by the compiler, case-insensitively, to be configured. `<value>` must be one of the following: error, warn, info, hidden, suppress. Please read the [Code Analysis documentation](https://docs.microsoft.com/en-us/dotnet/fundamentals/code-analysis/configuration-options#severity-level) for more details.

*Example:*

Configure the StyleCop analyzer so that empty comments are errors.

```ini
[*.{cs,vb}]

# The C# comment does not contain any comment text.
dotnet_diagnostic.SA1120.severity = error
```
125 changes: 125 additions & 0 deletions documentation/format/docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
# Welcome to the dotnet-format docs!

## .editorconfig options
- [Supported .editorconfig options](./Supported-.editorconfig-options.md)

## CLI options

### Specify a workspace (Required)

A workspace path is needed when running dotnet-format. By default, the current folder will be used as the workspace path. The workspace path and type of workspace determines which code files are considered for formatting.

- Solutions and Projects - By default dotnet-format will open the workspace path as a MSBuild solution or project.
- `--no-restore` - When formatting a solution or project the no restore option will stop dotnet-format from performing an implicit package restore.
- `--folder` - When the folder options is specified the workspace path will be treated as a folder of code files.

*Example:*

Format the code files used in the format solution.

```console
dotnet format ./format.sln
```

Format the code files used in the dotnet-format project.

```console
dotnet format ./src/dotnet-format.csproj
```

Format the code files from the `./src` folder.

```console
dotnet format whitespace ./src --folder
```

### Whitespace formatting

Whitespace formatting includes the core .editorconfig settings along with the placement of spaces and newlines. The whitespace formatter is run by default when not running analysis. When only performing whitespace formatting, an implicit restore is not perfomed. When you want to run analysis and fix formatting issues you must specify both.

Whitespace formatting run by default along with code-style and 3rd party analysis.

```console
dotnet format ./format.sln
```

Running the whitespace formatter alone.

```console
dotnet format whitespace ./format.sln
```

### Running analysis

#### CodeStyle analysis

Running codestyle analysis requires the use of a MSBuild solution or project file as the workspace. By default an implicit restore on the solution or project is performed. Enforces the .NET [Language conventions](https://docs.microsoft.com/en-us/visualstudio/ide/editorconfig-language-conventions?view=vs-2019) and [Naming conventions](https://docs.microsoft.com/en-us/visualstudio/ide/editorconfig-naming-conventions?view=vs-2019).

- `dotnet format style --severity <severity>` - Runs analysis and attempts to fix issues with severity equal or greater than specified. If severity is not specified then severity defaults to warning.

*Example:*

Code-style analysis is run by default along with whitespace formatting and 3rd party analysis.

```console
dotnet format ./format.sln
```

Run code-style analysis alone against the dotnet-format project.

```console
dotnet format style ./src/dotnet-format.csproj --severity error
```

Errors when used with the `--folder` option. Analysis requires a MSBuild solution or project.

```console
dotnet format style ./src --folder
```

#### 3rd party analysis

Running 3rd party analysis requires the use of a MSBuild solution or project file as the workspace. By default an implicit restore on the solution or project is performed. 3rd party analyzers are discovered from the `<PackageReferences>` specified in the workspace project files.

- `dotnet format analyzers --severity <severity>` - Runs analysis and attempts to fix issues with severity equal or greater than specified. If no severity is specified then this defaults to warning.

#### Filter diagnostics to fix

Typically when running codestyle or 3rd party analysis, all diagnostics of sufficient severity are reported and fixed. The `--diagnostics` option allows you to target a particular diagnostic or set of diagnostics of sufficient severity.

- `--diagnostics <diagnostic ids>` - When used in conjunction with `style` or `analyzer` subcommands, allows you to apply targeted fixes for particular analyzers.

*Example:*

Run code-style analysis and fix unused using directive errors.

```console
dotnet format style ./format.sln --diagnostics IDE0005
```

### Filter files to format

You can further narrow the list of files to be formatted by specifying a list of paths to include or exclude. When specifying folder paths the path must end with a directory separator. File globbing is supported.

- `--include` - A list of relative file or folder paths to include in formatting.
- `--exclude` - A list of relative file or folder paths to exclude from formatting.

*Example:*

Other repos built as part of your project can be included using git submodules. These submodules likely contain their own .editorconfig files that are set as `root = true`. This makes it difficult to validate formatting for your project as formatting mistakes in submodules are treated as errors.

The following command sets the repo folder as the workspace. It then includes the `src` and `tests` folders for formatting. The `submodule-a` folder is excluded from the formatting validation.

```console
dotnet format whitespace --folder --include ./src/ ./tests/ --exclude ./src/submodule-a/ --verify-no-changes
```

### Logging and Reports

- `--verbosity` - Set the verbosity level. Allowed values are q[uiet], m[inimal], n[ormal], d[etailed], and diag[nostic]
- `--report` - Writes a json file to the given directory. Defaults to 'format-report.json' if no filename given.
- `--binarylog` - Writes a [binary log file](https://msbuildlog.com/) to help in diagnosing solution or project load errors. Defaults to 'format.binlog' if no filename given.

### Validate formatting

- `--verify-no-changes` - Formats files without saving changes to disk. Terminates with a non-zero exit code (`2`) if any files were formatted.
31 changes: 31 additions & 0 deletions documentation/format/docs/Supported-.editorconfig-options.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Supported .editorconfig options
The dotnet-format global tool supports the core set of [EditorConfig options](https://github.com/editorconfig/editorconfig/wiki/EditorConfig-Properties)* as well as the [.NET coding convention settings for EditorConfig](https://docs.microsoft.com/en-us/visualstudio/ide/editorconfig-code-style-settings-reference?view=vs-2019).

## Core options
- indent_style
- indent_size
- tab_width
- end_of_line
- charset
- insert_final_newline
- root

[*] The options `trim_trailing_whitespace` and `max_line_length` are not supported. Currently insignificant whitespace is **always** removed by the formatter.

## Removing unnecessary imports
In order to remove unnecessary imports the IDE0005 (unnecessary import) diagnostic id must be configured in your .editorconfig. When running dotnet-format specify a severity that includes the configured IDE0005 severity.

*Example:*

.editorconfig
```ini
root = true

[*.{cs,vb}]
dotnet_diagnostic.IDE0005.severity = warning
```

command
```console
dotnet format ./format.sln --severity warn
```
90 changes: 90 additions & 0 deletions documentation/format/docs/integrations.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
# Integrations
Collection of advice how to auto check/format. Every sample expects dotnet format installed as local tool, unless otherwise noted.

## Git pre-commit hook to reformat

Create file `.git/hooks/pre-commit` with following contents:
```sh
#!/bin/sh
LC_ALL=C
# Select files to format
FILES=$(git diff --cached --name-only --diff-filter=ACM "*.cs" | sed 's| |\\ |g')
[ -z "$FILES" ] && exit 0

# Format all selected files
echo "$FILES" | cat | xargs | sed -e 's/ /,/g' | xargs dotnet format --include

# Add back the modified files to staging
echo "$FILES" | xargs git add

exit 0

```

These instructions originally authored by [randulakoralage82](https://medium.com/@randulakoralage82/format-your-net-code-with-git-hooks-a0dc33f68048).


## Check on PR in Azure Dev Ops

Add following to your build file:

```yaml
- task: UseDotNet@2
displayName: 'Use .NET 6 sdk'
inputs:
packageType: 'sdk'
version: '6.0.x'
includePreviewVersions: true

- task: DotNetCoreCLI@2
displayName: 'dotnet-format'
inputs:
command: 'custom'
custom: 'format'
arguments: '--verify-no-changes'
```

These instructions originally authored by [leotsarev](https://github.com/joinrpg/joinrpg-net/).


## [pre-commit.com](https://pre-commit.com/) hook to reformat

Add the following block to the `repos` section of your `.pre-commit-config.yaml` file:

```yaml
- repo: https://github.com/dotnet/format
rev: "" # Specify a tag or sha here, or run "pre-commit autoupdate"
hooks:
- id: dotnet-format
```
Note that this will compile and install dotnet format to an isolated environment, using the system installation of the dotnet CLI. See the [pre-commit.com documentation](https://pre-commit.com/#dotnet) for more details. The problem is that dotnet format is using *preview* SDK (even for 5.x versions), and you have to install preview SDK on your machine for compiling it. Another option is to use local feature of pre-commit, as follows:

```yaml
- repo: local
hooks:
#Use dotnet format already installed on your machine
- id: dotnet-format
name: dotnet-format
language: system
entry: dotnet format --include
types_or: ["c#", "vb"]
```

These instructions originally authored by [rkm](https://github.com/rkm) & [leotsarev](https://github.com/joinrpg/joinrpg-net/).


## Rider reformat on save

1. Open Settings -> Tools -> File Watchers
1. Press The “Plus Sign” to Add a Custom watcher
1. Set the name to i.e. “dotnet format on save”
1. FileType: C#
1. Scope: Open Files
1. Program: Write dotnet-format
1. Arguments: $SolutionPath$ --verbosity diagnostic --include $FileRelativePath$
1. (Optionally) Append --fix-style warning to fix any style issues automatically on save.
1. (Optionally) Append --fix-analyzers warning to fix any analyzer warnings on save.
1. Disable all advanced option checkboxes.
1. All other values were left default

These instructions originally authored by [Nils Henrik Hals](https://strepto.github.io/Pause/blog/dotnet-format-rider/).
Loading