Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/bagtoad/gh-sarif

A GitHub CLI extension for interacting with Code Scanning analyses and SARIF files
https://github.com/bagtoad/gh-sarif

gh-extension

Last synced: 3 days ago
JSON representation

A GitHub CLI extension for interacting with Code Scanning analyses and SARIF files

Awesome Lists containing this project

README

        

# GH-SARIF

Interact with Code Scanning analysis and SARIF files.

`gh-sarif` is a [GitHub CLI](https://github.com/cli/cli) extension.

## Installation

```sh
gh extension install bagtoad/gh-sarif
```

## Usage

```
Usage:
gh sarif [command]

Available Commands:
completion Generate the autocompletion script for the specified shell
delete Delete a GitHub Code Scanning Analysis
help Help about any command
list List GitHub Code Scanning analyses for a repository
upload Upload a SARIF file to GitHub Code Scanning
view View GitHub Code Scanning analysis or SARIF results

Flags:
-h, --help help for gh-sarif
-j, --json Output JSON instead of text (includes additional fields)
-R, --repo string GitHub repository (format: owner/repo)

Use "gh sarif [command] --help" for more information about a command.
```

### List Analyses for a Repository

```sh
gh sarif list
```
### View Analysis Results in a Table

```sh
gh sarif view
```

### View Analysis Results as SARIF

```sh
gh sarif view --sarif
```

### View Analysis Results as CSV

```sh
gh sarif view --csv
```

### View Analysis Results from a Local SARIF File

```sh
gh sarif view
```

### Upload a SARIF File to GitHub Code Scanning

```sh
gh sarif upload
```

### Delete an Analysis

```sh
gh sarif delete
```

### Delete Multiple Analyses

```sh
gh sarif delete ...
```

### Delete All Analyses in the set Except the Last

```sh
gh sarif delete --delete-all
```

### Delete All Analyses in the set, Including the Last

```sh
gh sarif delete --delete-all --confirm-delete
```

or

```sh
gh sarif delete --purge
```