-
Notifications
You must be signed in to change notification settings - Fork 6k
Formatting on console-teleprompter #1210
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
Formatting on console-teleprompter #1210
Conversation
Update console-teleprompter.md Update console-teleprompter.md Update console-teleprompter.md
Open Publishing Build Service: The pull request content has been published and here are some changed files links of this time:
Status: Succeeded. |
@@ -239,8 +238,8 @@ steps in it and by the end, you’ll have all the updates that you need. | |||
The first step is to create an asynchronous `Task` returning method that | |||
represents the code you’ve created so far to read and display the file. | |||
|
|||
Add this method to your Program class: (It’s taken from the body of your | |||
Main method: | |||
Add this method to your Program class (It’s taken from the body of your |
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.
- I think
Program
should be formatted as code - "It's" should be lowercase, since it is part of the sentence now
@svick I made the suggested updates. |
✅ Validation status: passed
For more details, please refer to the build report. Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report. |
@@ -111,14 +112,14 @@ using System.IO; | |||
``` | |||
|
|||
The `IEnumerable<T>` interface is defined in the | |||
`System.Collections.Generic` namespace. The File class is defined in the | |||
`System.IO namespace`. | |||
`System.Collections.Generic` namespace. The `File` class is defined in the |
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.
It might be better to change File
to @System.IO.File so that it's resolved as a link.
implement the `IDisposable` interface. The `IDisposable` interface | ||
defines a single method, `Dispose()`, that should be called when the | ||
defines a single method, `Dispose`, that should be called when the |
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.
Here again, it might be better to change these from IDisposable
to @System.IDisposable, and from Dispose
to @System.IDisposable.Dispose so that they resolve as links.
*implicitly typed local variable*. That means the type of the variable is | ||
determined by the compile time type of the object assigned to the | ||
variable. Here, that is the return value from `File.OpenText()`, which is | ||
variable. Here, that is the return value from `File.OpenText`, which is | ||
a `StreamReader` object. |
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.
Here again, FIle.OpenText
could be File.OpenText so it resolves as a link. Similarly, @System.IO.StreamReader instead of StreamReader
.
@@ -239,8 +238,8 @@ steps in it and by the end, you’ll have all the updates that you need. | |||
The first step is to create an asynchronous `Task` returning method that |
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.
Task-returning. Task could be a link -- @System.Threading.Tasks.Task.
@@ -258,25 +257,25 @@ private static async Task ShowTeleprompter() | |||
``` | |||
|
|||
You’ll notice two changes. First, in the body of the method, instead of | |||
calling `Wait()` to synchronously wait for a task to finish, this version | |||
calling `Wait` to synchronously wait for a task to finish, this version |
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.
Maybe resolve this as a link -- @System.Threading.Tasks.Task.Wait.
@BillWagner
@@ -310,12 +309,12 @@ private static async Task GetInput() | |||
|
|||
This creates a lambda expression to represent an `Action` that reads a key |
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.
Here the link would be helpful -- @System.Action. Also, perhaps "Action delegate"?
@@ -310,12 +309,12 @@ private static async Task GetInput() | |||
|
|||
This creates a lambda expression to represent an `Action` that reads a key | |||
from the Console and modifies a local variable representing the delay when | |||
the user presses the ‘<’ or ‘>’ keys. This method uses `Console.ReadKey()` | |||
the user presses the ‘<’ or ‘>’ keys. This method uses `Console.ReadKey` |
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.
Replace with a link to @System.Console.ReadKey?
@@ -376,11 +375,11 @@ private static async Task RunTeleprompter() | |||
} | |||
``` | |||
|
|||
The one new method here is the `Task.WhenAny()` call. That creates a Task | |||
The one new method here is the `Task.WhenAny` call. That creates a `Task` |
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.
Replace with a link to Task.WhenAny?
Responded to @rpetrusha feedback and re-squashed. |
@rpetrusha I made all your suggested changes. Do you want to review again, or is it ready to ship? |
✅ Validation status: passed
For more details, please refer to the build report. Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report. |
@BillWagner I'll review it again quickly. |
implement the `IDisposable` interface. The `IDisposable` interface | ||
defines a single method, `Dispose()`, that should be called when the | ||
initialized in the `using` statement (`reader`, in this example) must | ||
implement the `IDisposable` interface. The @System.IDisposables interface |
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.
typo: @System.IDisposable
*implicitly typed local variable*. That means the type of the variable is | ||
determined by the compile time type of the object assigned to the | ||
variable. Here, that is the return value from `File.OpenText()`, which is | ||
a `StreamReader` object. | ||
variable. Here, that is the return value from @File.OpenTexts, which is |
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.
should be @System.IO.File.OpenText
variable. Here, that is the return value from `File.OpenText()`, which is | ||
a `StreamReader` object. | ||
variable. Here, that is the return value from @File.OpenTexts, which is | ||
a @System.IO.sStreamReader object. |
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.
typo: @System.IO.StreamReader
@@ -376,11 +375,11 @@ private static async Task RunTeleprompter() | |||
} | |||
``` | |||
|
|||
The one new method here is the `Task.WhenAny()` call. That creates a Task | |||
The one new method here is the @System.Threading.Tasks.Task.WhenAny call. That creates a `Task` |
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.
This doesn't resolve. Should be @System.Threading.Tasks.Task.WhenAny(System.Threading.Tasks.Task[]).
@BillWagner A few links didn't resolve. For the last one, you could also use |
Also, updated the freshness date, and add the ms.author metadata tag. Respond to updated feedback Respond to @rpetrusha feedback. Fix a few broken links
✅ Validation status: passed
For more details, please refer to the build report. Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report. |
rebasing and merging. Thanks @rpetrusha |
This addresses the final feedback in PR #1073. I’ll close that PR as this replaces it.
Important: Please to a merge commit instead of a squash commit when we merge this. We want to preserve the original PR commits, including the committer