-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Names -> Keywords batch 10 #6973
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
Names -> Keywords batch 10 #6973
Conversation
Replacing full type names with keywords when appropriate Files affected: operations1.cs, parse2.cs, parse3.cs, tryparseex.cs, bcopy.cs, getbyte.cs, setbyte.cs, systembyte.cs, tostring.cs, charstructure.cs. See dotnet#6920
closing and reopening to trigger the samples CI build |
@BillWagner I just want to 100% verify. Is it really the way you want me to do this? Is it convenient for you or other reviewers? Because there are 150 more branches to merge, those were only 20 or about that. |
Docs Build status updates of commit c9bad0e: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
@WhiteBlackGoose Thanks for reaching out. Here's a detailed update: Yes, we do like these changes. Making them is also driving us to add a check that we've had in the docs repo for some time now: a CI build on all sample code. Briefly, the snippets 5000 checks any PR that changes source code to ensure the code changed is included in a project, and if so, it builds that project. For historical reasons, the sample code in this repo typically didn't have a project file. It was migrated from an internal system that did verification builds. Our expectation is that these changes will fail in the snippets 5000 build because most of these folders won't have a project file. The fix is reasonably simple: add a project file for a console app. Right now, the project file can use .NET Core 3.1 (latest LTS), .NET 5 (latest release) or .NET 6 (preview). Our version checker will flag any version that's out of support on a monthly basis. One challenge we've had in some folders is where there are multiple Let us know how that works, if you are are comfortable doing these extra steps on these PRs. It will really help us validate the quality of these samples. I'll wait to review the other PRs opened recently while we concentrate on this first PR. |
@BillWagner so, I have to add a project file to each folder, right? Then here's a question. Why not to add it to each file, instead of each folder? Iirc all snippets are runnable independently, hence we can do it. |
Currently the build system wants a single project per folder. To do multiple projects you would have to move the files to sub folders and add projects to each folder. Then you would have to update the articles that reference the sample, it's a bit more work. Adding the project file is generally simple, as Bill pointed out. However, with multiple main objects, you may actually need to specify the |
That's true. I do find that I like being able to run the samples locally. That's why I've added that. |
triggering a fresh build. |
@WhiteBlackGoose The last snippets 5000 build shows the errors we'd expect from missing project files. |
Docs Build status updates of commit c9bad0e: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code changes look fine. Will leave the CI/build issues to the docs folks
@pgovind @adamsitnik I just didn't have time yet to add the necessary files, as per Bill Wagner's comment. Sorry, should've converted the PR to draft |
Docs Build status updates of commit f7a60f0: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
closing and reopening for a fresh build. |
Docs Build status updates of commit f7a60f0: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
I'm going to close this PR since the snippets have all moved to new folders. Feel free to continue this work in the new snippet folder structure. Also, most snippets should have associated project files now, so you won't need to add too many of those. |
Replacing full type names with keywords when appropriate
Files affected: operations1.cs, parse2.cs, parse3.cs, tryparseex.cs, bcopy.cs, getbyte.cs, setbyte.cs, systembyte.cs, tostring.cs, charstructure.cs.
See #6920