Skip to content

Support remapping all severity levels #138

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
merged 7 commits into from
Oct 31, 2023

Conversation

dawedawe
Copy link
Contributor

@dawedawe dawedawe commented Oct 30, 2023

  • mark all CLI args as unique
  • print messages when using FSC args, too
  • support remapping of all severity levels
  • support passing of multiple --project flags
  • support passing of multiple --analyzers-path flags

- print messages when using FSC args, too
- support remapping of all severity levels
| Report of string
| FSC_Args of string
| Verbose
| [<Unique>] Project of string list
Copy link
Collaborator

@baronfel baronfel Oct 30, 2023

Choose a reason for hiding this comment

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

does Unique require only a single instance of each of these flags? It's often nicer/easier for users (especially automated scripts!) to specify the same flag multiple times, aggregating all of the values of each time the flag is provided.

> app --project myproject.fsproj --project anotherproject.fsproj

is the same as

> app --project myproject.fsproj,anotherproject.fsproj

Copy link
Contributor Author

@dawedawe dawedawe Oct 30, 2023

Choose a reason for hiding this comment

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

Okay, that's supported now. I did the same for --analyzers-path as it felt somewhat related to proj paths.
I'm not sure about the other ones.

Copy link
Contributor

@nojaf nojaf left a comment

Choose a reason for hiding this comment

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

This looks good. But I'm a little lost by the --project changes.


if not (severityMapping.IsValid()) then
printError
"An analyzer code may only be listed once in the <fail-on-warnings> and <treat-as-severity> arguments."
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this is a bit questionable.
Fail On Warnings feels like the ugly duck. Is this not, in concept, replaced by TreatAsError?

Copy link
Contributor

@nojaf nojaf left a comment

Choose a reason for hiding this comment

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

Looks good

@dawedawe dawedawe merged commit 7605eaf into ionide:master Oct 31, 2023
@dawedawe dawedawe deleted the severity_remap branch October 31, 2023 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants