Skip to main content

Quickstart

Checkup was created to optimize writing tasks that enable you to gather the information that's useful to you, and use that information to make decisions. Checkup allows you to:

  • Create and manage Plugins
  • Write Tasks
  • Add Task Actions to provide calls to actions
  • Utilize the SARIF output in external tools

Checkup can be used through the command line, or programmatically through the Node API.

Step 1: Install Checkup

Checkup has it's own CLI for running tasks, installable via npm or yarn.

npm i -D @checkup/cli

The Node API, which provides a way to run tasks programmatically, can also be accessed through the @checkup/cli package.

Step 2: Create a configuration file

Checkup uses a configuration file to define the plugins and tasks to run. You can create a configuration file by running the following command in the root of your project:

npx checkup generate config

This will generate a .checkuprc file in the current directory, with the following contents:

.checkuprc
{
"$schema": "https://raw.githubusercontent.com/checkupjs/checkup/master/packages/core/src/schemas/config-schema.json",
"excludePaths": [],
"plugins": [],
"tasks": {}
}

Config file options

  • excludePaths: A list of paths to exclude from analysis.
  • plugins: A list of plugins to load.
  • tasks: A list of tasks to run.

Step 3: Add plugins

In order to run checkup, you must add plugins to your configuration file. Add plugins to your project by running the following command:

npm i -D checkup-plugin-example

Then, edit the .checkuprc file that was created and add the plugin to your configuration file:

.checkuprc
{
"$schema": "https://raw.githubusercontent.com/checkupjs/checkup/master/packages/core/src/schemas/config-schema.json",
"excludePaths": [],
"plugins": ["checkup-plugin-example"],
"tasks": {}
}

Step 4: Run the CLI

Finally, run the CLI in the root of your project to run your tasks:

npx checkup run .

Checkup will run the tasks in the configured plugins, and output the results to a SARIF file by default.

You can also analyze your results using a SARIF viewer. See analyzing results for more information.