-
Notifications
You must be signed in to change notification settings - Fork 94
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
Enable automation details for command base #2407
Conversation
@@ -220,6 +220,14 @@ public bool ShouldSerializeGraphs() | |||
return this.Graphs.HasAtLeastOneNonDefaultValue(Graph.ValueComparer); | |||
} | |||
|
|||
public bool ShouldSerializeAutomationDetails() | |||
{ | |||
return this.AutomationDetails?.Description != null || |
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.
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.
The Description isn't a string, it is a Message type. It's why I didn't change to IsNullOrWhiteSpace check
/// </summary> | ||
public partial class RunAutomationDetails | ||
{ | ||
public bool ShouldSerializeDescription() => this.Description != null; |
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.
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.
The Description isn't a string, it is a Message type. It's why I didn't change to IsNullOrWhiteSpace check
public string BaselineSarifFile { get; set; } | ||
|
||
[Option( | ||
"automationId", |
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.
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.
just moved! :)
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.
Description
Imagine SARIF Pattern Matcher being run by someone, and we want to automatically ingest the output SARIF somehow.
With this, we could ask the user to run SARIF Pattern Matcher and pass
--automationId
and--automationGuid
, that information would be stored in the SARIF and we would know that the SARIF was generated by a specific team.Follow-up change
Change the
commandBase
to accept a URI and this URI will be used to send the generated SARIF to that endpoint.cc: @cfaucon