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

Console: show URL for the rule at summary #666

Merged
merged 3 commits into from
Jan 13, 2024
Merged
Changes from all commits
Commits
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
2 changes: 2 additions & 0 deletions src/FSharpLint.Console/Output.fs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@ type StandardOutput () =
member __.WriteInfo (info:string) = writeLine info ConsoleColor.White Console.Out
member this.WriteWarning (warning:Suggestion.LintWarning) =
let highlightedErrorText = highlightErrorText warning.Details.Range warning.ErrorText
let ruleUrlHint = sprintf "See https://fsprojects.github.io/FSharpLint/how-tos/rules/%s.html" warning.RuleIdentifier
let str = warning.Details.Message + Environment.NewLine + highlightedErrorText
+ Environment.NewLine + ruleUrlHint
writeLine str ConsoleColor.Yellow Console.Out
String.replicate 80 "-" |> (this :> IOutput).WriteInfo
member __.WriteError (error:string) = writeLine error ConsoleColor.Red Console.Error
Expand Down
Loading