fsprojects / fsprojects/FSharpLint
CLI tool: add flag to print ONLY warnings
Open
Nobody has claimed this yet.
enhancement
- Dominant language
- F#
- Stars
- 327
- Forks
- 74
- PR merge metrics
- No merged PRs in 30d
Description
Description
The current output of the CLI tool includes the lint progress and result for every file. It would be nice to have a way to filter out successful results and only print the warnings.
Repro steps
- dotnet fsharplint -f "foo.fsproj"
Expected behavior
========== Linting File2.fs ==========
blah
========== Finished: 1 warnings ==========
========== Summary: 1 warnings ==========
Actual behavior
========== Linting File1.fs ==========
========== Finished: 0 warnings ==========
========== Linting File2.fs ==========
blah
========== Finished: 1 warnings ==========
========== Linting File3.fs ==========
========== Finished: 0 warnings ==========
========== Summary: 1 warnings ==========
Known workarounds
Piping the output into another tool, i.e. grep:
dotnet fsharplint -f "foo.fsproj" | grep -Pzo '(?s)=+ Linting (\N*) =+\n(?!=+ Finished: 0 warnings =+\n).*?=+ Finished: [^0] warnings =+\n'
Related information
- Operating system: Windows 10 Pro
- dotnet-fsharplint version: 0.11.1
- .NET Core version: 2.1.505
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the dotnet fsharplint -f "foo.fsproj" CLI entry point and trace how lint progress and per-file results are printed. Define the new warnings-only flag and verify it suppresses files with zero warnings while retaining warning output and the summary shown in the expected behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- fsharp
- Domain
- cli, tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100