@@ -47,14 +47,22 @@ export enum SARIF_UPLOAD_ENDPOINT {
4747
4848// Represents configurations for different analysis kinds.
4949export interface AnalysisConfig {
50+ /** The analysis kind the configuration is for. */
51+ kind : AnalysisKind ;
52+ /** A display friendly name for logs. */
5053 name : string ;
54+ /** The API endpoint to upload SARIF files to. */
5155 target : SARIF_UPLOAD_ENDPOINT ;
56+ /** A predicate on filenames to decide whether a SARIF file
57+ * belongs to this kind of analysis. */
5258 sarifPredicate : ( name : string ) => boolean ;
59+ /** A prefix for environment variables used to track the uniqueness of SARIF uploads. */
5360 sentinelPrefix : string ;
5461}
5562
5663// Represents the Code Scanning analysis configuration.
5764export const CodeScanning : AnalysisConfig = {
65+ kind : AnalysisKind . CodeScanning ,
5866 name : "code scanning" ,
5967 target : SARIF_UPLOAD_ENDPOINT . CODE_SCANNING ,
6068 sarifPredicate : ( name ) =>
@@ -64,6 +72,7 @@ export const CodeScanning: AnalysisConfig = {
6472
6573// Represents the Code Quality analysis configuration.
6674export const CodeQuality : AnalysisConfig = {
75+ kind : AnalysisKind . CodeQuality ,
6776 name : "code quality" ,
6877 target : SARIF_UPLOAD_ENDPOINT . CODE_QUALITY ,
6978 sarifPredicate : ( name ) => name . endsWith ( ".quality.sarif" ) ,
0 commit comments