Hashboard build command

The build command is the primary command you can use to create, update, and delete Hashboard resources using code.

A Hashboard build is a collection of changes that you've defined as code and can be validated, previewed, and applied to your project. Builds make forking and experimenting with Hashboard from the command line cheap and easy.

When you create a build, Hashboard will do the following:

  1. Validate your Hashboard configuration files and dbt configuration (if using the dbt integration)
  2. Validate that any models in the build are compatible with their underlying data sources
  3. Provide you with a link to the build summary, where you can see details of the proposed changes, preview them, and apply them to your project

Creating a build and previewing changes

Run hb init

If you have not already, configure the root of your Hashboard project (and optionally your dbt project) with hb init.

Create a build

Run hb build, or equivalently hb build create.

hb build

This evaluates all files in your current directory, any nested directories, and your dbt models (if you've setup).

🔑 Logged in to your-project-name

╭─ 📦 Build w9ZLaOUZVXhbxxxx ───────────────────────────╮
│                                                       │
│  Update                                               │
│  ~ Customers Model                                    │
│                                                       │
│  View build                                           │
│  https://hashboard.com/app/p/builds/w9ZLaOUZVXhbxxxx  │
│                                                       │
╰───────────────────────────────────────────────────────╯

Check and apply these changes at the link or use `hb build apply`.

You can scope your build to specific resources by providing a list of filepath globs or dbt selectors to the build command.

hb build path/to/hashboard-files/* dbt:modified

View the build

Go to the build link at the bottom of the build details. The build page displays a list of the built resources with live preview links and code diffs.

Apply the build: hb build apply

Run hb build apply to apply the build you last created. You will shown the details of the last build you created and be asked to confirm.

hb build apply
🔑 Logged in to your-project-name

╭─ 📦 Build w9ZLaOUZVXhbxxxx ───────────────────────────╮
│                                                       │
│  Unchanged                                            │
│  ~ Customers Model                                    │
│                                                       │
│  View build                                           │
│  https://hashboard.com/app/p/builds/w9ZLaOUZVXhbxxxx  │
│                                                       │
╰───────────────────────────────────────────────────────╯

Confirm and apply these changes to your project? [y/n]: y

Once you confirm, the build will be applied and the CLI will show an applied badge.

🔑 Logged in to your-project-name

╭─ 📦 Build w9ZLaOUZVXhbxxxx ───────────────────────────╮
│                                                       │
│  Update                                               │
│  ~ Customers Model                                    │
│                                                       │
│  View build                                           │
│  https://hashboard.com/app/p/builds/w9ZLaOUZVXhbxxxx  │
│                                                       │
╰───────────────────────────────────────── ✅ Applied  ─╯