Improvement to project files using Directory.Build.props #1566
Conversation
Directory.Build.props
Outdated
@@ -1,10 +1,10 @@ | |||
<!-- Contains required properties for osu!framework projects. --> | |||
<Project> | |||
<PropertyGroup Label="C#"> | |||
<LangVersion>7</LangVersion> | |||
<LangVersion>7.3</LangVersion> |
smoogipoo
May 25, 2018
Contributor
We are not ready to jump into 7.3 just yet. Not supported on the latest mono preview even.
We are not ready to jump into 7.3 just yet. Not supported on the latest mono preview even.
huoyaoyuan
May 25, 2018
Author
Contributor
JetBrains supports 7.2 about a month ago, but Mono support for 7.2 is still in preview. So revert language version to 7.0, and keep other changes?
JetBrains supports 7.2 about a month ago, but Mono support for 7.2 is still in preview. So revert language version to 7.0, and keep other changes?
smoogipoo
May 25, 2018
Contributor
Revert to 7.0 for now I'd say.
Revert to 7.0 for now I'd say.
I don't know if we'll be using roslyn analysers going forward, they need more discussion. |
Cool stuff |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
I'm working on my own project these days, and found some noticeable things.
The special name
Directory.Build.props
will be automatically imported by latest MSBuild.Common property file should use relative path from itself.
The service guid is for unit test, so it's sure to keep it only in test project. (If ci is happy for this)
Justification:
Should latest language version be introduced? C# releases minor versions rapidly now, and third-party tools may not understand it, especially for non-Visual Studio users.
But C# 7.x has improved some performance (span and readonly struct), making minor version update worth while.
Roslyn team is interested in enforcing code style at build time. Should I introduce rules in editor config now?