brick
The brick group generates and manages bricks — the reusable components that package data-processing code for the Constellab platform. Use it to scaffold a new brick, install its pip dependencies, add GitHub Copilot instruction files, apply gws_core code migrations, and publish a brick's version and technical documentation to the Constellab community.
brick generate
Scaffolds a new brick with the standard boilerplate code and folder structure. Run this when starting a new brick so you get a ready-to-use skeleton instead of building the layout by hand. Use a snake_case name for the brick.
gws brick generate
gws brick generate my_new_brick
brick install-deps
Reads a brick's settings.json and installs every pip package it declares. Each pip source is installed with its own pip install command. Use this after cloning a brick or after adding dependencies to settings.json. If no brick path is given, the current directory is used. The command exits with a non-zero status if any package fails to install.
gws brick install-deps [BRICK_PATH]
# Install deps for the brick in the current folder
gws brick install-deps
# Install deps for a brick at an explicit path
gws brick install-deps /lab/user/bricks/gws_core
brick configure
Configures a brick with GitHub Copilot instruction files under its .github/ folder. Run this to add or refresh the Copilot guidance for a brick. If no brick path is given, the current directory is used. Existing generated files are left untouched unless you pass --force.
gws brick configure [BRICK_PATH] [OPTIONS]
# Configure the current brick, overwriting existing files
gws brick configure --force
brick code-migrate
Applies gws_core code migrations (source-to-source refactors) to a brick's src directory. By default it runs every migration newer than the gws_core version the brick targets (read from settings.json): it describes each migration, lists the impacted files, and asks a single confirmation before applying. Use --list to see the available migrations, --version to run only one, --dry-run to preview the diffs, and --yes to skip the confirmation. If no brick path is given, the current directory is used.
gws brick code-migrate [BRICK_PATH] [OPTIONS]
# List all available migrations
gws brick code-migrate --list
# Preview the diffs for the current brick without touching files
gws brick code-migrate --dry-run
# Run only the migration for gws_core 0.22.0
gws brick code-migrate --version 0.22.0
brick technical-doc push
Pushes a brick's technical documentation to the Constellab community, without publishing a new version. Use this to refresh the published docs on their own after editing them. If no brick path is given, the current directory is used.
gws brick technical-doc push [BRICK_PATH]
# Push the technical documentation of the current brick
gws brick technical-doc push
brick version push
Publishes a new brick version to the Constellab community. It reads the version from the brick's settings.json, verifies a matching git tag exists (offering to create and push the tag if it does not), asks for confirmation, and then publishes the version. After publishing it can also push the brick's technical documentation. If no brick path is given, the current directory is used.
gws brick version push [BRICK_PATH] [OPTIONS]
# Push the current brick's version, with prompts
gws brick version push
# Publish without prompts and push the technical documentation too (CI use)
gws brick version push --yes --technical-doc