CodeQL Packs¶
CodeQL Pack¶
- class ghastoolkit.CodeQLPack(path: str | None = None, library: bool | None = None, name: str | None = None, version: str | None = None, cli: CodeQL | None = None)¶
CodeQL Pack class.
- __init__(path: str | None = None, library: bool | None = None, name: str | None = None, version: str | None = None, cli: CodeQL | None = None) None¶
Initialise CodeQL Pack.
- __str__() str¶
To String.
- codeql_packages: str = '/home/runner/.codeql/packages'¶
CodeQL Packages Location
- create() str¶
Create / Compile a CodeQL Pack.
- static download(name: str, version: str | None = None) CodeQLPack¶
Download a CodeQL Pack.
- static findByQuery(query_path: str) CodeQLPack | None¶
Find Pack by query path.
- install(display: bool = False)¶
Install Dependencies for a CodeQL Pack.
- load()¶
Load QLPack file.
- publish()¶
Publish a CodeQL Pack to a remote registry.
- property qlpack: str¶
QL Pack Location.
- property remote_version: str | None¶
Gets the remote version of the pack if possible.
- resolveQueries(suite: str | None = None) List[str]¶
Resolve all the queries in a Pack and return them.
- run(*args, display: bool = False) str | None¶
Run Pack command.
- updatePack() dict[str, Any]¶
Update Local CodeQL Pack.
- updateVersion(name: str = 'patch', version: str | None = None) str¶
Update CodeQL Pack version.
- validate() bool¶
Validate and check if the path is a valid CodeQL Pack.
CodeQL Packs¶
- class ghastoolkit.CodeQLPacks(path: str | None = None)¶
CodeQL List of Packs.
- __init__(path: str | None = None) None¶
Initialise CodeQLPacks.
- __len__() int¶
Get length / amount of loaded packs.
- __str__() str¶
To String.
- append(pack: CodeQLPack)¶
Append a CodeQLPack.
- load(path: str)¶
Load packs from path.