CodeQLAliases.

CodeQLCreateDatabase(ICakeContext, CodeQLCreateDatabaseToolSettings) Method

Summary

Creates a CodeQL Databases that can be use for vunerability scanning. Assumes the codeQL cli is installed on the host and available in the terminal path.
Assembly
Cake.CodeQL.Cli.dll
Namespace
Cake.CodeQL.Cli
Containing Type
CodeQLAliases

Syntax

public static void CodeQLCreateDatabase(this ICakeContext context, CodeQLCreateDatabaseToolSettings settings)

Examples

Creates a CodeQL database in a specific working directory.

CodeQLCreateDatabase(new CodeQLCreateDatabaseToolSettings
   {
        DatabaseDir = "./tools/codeql-db",
        WorkingDirectory = "./",
        SourceRootDir = "./src",
        BuildCommand = "dotnet build /t:rebuild",
        NoRunUnnecessaryBuilds = true,
        Languages = { CodeLanguage.csharp }
   });

Attributes

Type Description
CakeMethodAliasAttribute
CakeAliasCategoryAttribute

Parameters

Name Type Description
context ICakeContext The context.
settings CodeQLCreateDatabaseToolSettings The settings.

Return Value

Type Description
void