Skip to content

Adjusted newlines in non-pretty output for consistency #23470

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

Merged

Conversation

JoshuaKGoldberg
Copy link
Contributor

Fixes #23469

@mhegazy mhegazy requested a review from sheetalkamat April 17, 2018 17:10
@mhegazy
Copy link
Contributor

mhegazy commented Apr 17, 2018

@sheetalkamat any comments?

system.write(output);
} :
(diagnostic, newLine, options) => {
clearScreenIfNotWatchingForFileChanges(system, diagnostic, options);
let output = new Date().toLocaleTimeString() + " - ";
output += `${flattenDiagnosticMessageText(diagnostic.messageText, system.newLine)}${newLine + newLine + newLine}`;
let output = `${getPlainDiagnosticPrecedingNewLines(diagnostic, newLine)}${new Date().toLocaleTimeString()} - `;
Copy link
Member

Choose a reason for hiding this comment

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

This may depend on whether screen was cleared or not as well right ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@sheetalkamat thanks, it does!

@@ -75,7 +75,7 @@ namespace ts {
} :
(diagnostic, newLine, options) => {
clearScreenIfNotWatchingForFileChanges(system, diagnostic, options);
Copy link
Member

Choose a reason for hiding this comment

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

may be let clearScreenIfNotWatchingForFiles send you the return value if the screen is cleared since it is not cleared in options.extendedDiagostics || options.diagnostics too.

@mhegazy mhegazy merged commit 2826bc7 into microsoft:master Apr 20, 2018
@JoshuaKGoldberg JoshuaKGoldberg deleted the standardized-non-pretty-newlines branch April 20, 2018 17:02
@microsoft microsoft locked and limited conversation to collaborators Jul 30, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants