Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@buddy-js/cli

draconisNoctis1.8kMIT0.0.9TypeScript support: included

A IaC tool to create your [Buddy CI] pipelines programmatically via JS/TS.

buddy, IaC

readme

@buddy-js/cli

A IaC tool to create your [Buddy CI] pipelines programmatically via JS/TS.

oclif Version Downloads/week License

Installation

$ npm install @buddy-js/cli @buddy-js/core
$ yarn add @buddy-js/cli @buddy-js/core
$ pnpm add @buddy-js/cli @buddy-js/core

Usage

Create the index file, e.g. .buddy/buddy.mjs with the following content:

import { pipeline, action } from '@buddy-js/core';

pipeline('Production', {
  on: 'CLICK',
  refs: ['refs/heads/main'],
  actions: [
    action('Execute: pnpm test', 'BUILD', {
      docker_image_name: 'node',
      docker_image_tag: '22',
      execute_commands: [
        'pnpm install',
        'pnpm test'
      ]
    })
  ]
})

Commands

buddyjs generate [INPUT]

Generates YAML files for Buddy CI pipeline definitions

USAGE
  $ buddyjs generate [INPUT] [--json] [-o <value>] [--clear] [--cwd <value>] [--indent <value>] [--lineWidth
    <value>]

ARGUMENTS
  INPUT  [default: .buddy/buddy.{ts,mts,cts,js,mjs,cjs}] input file

FLAGS
  -o, --output=<value>  [default: .buddy] output directory
      --[no-]clear      [default: true] Remove all YAML files from output directory before generating
      --cwd=<value>     [default: .]

YAML FORMAT FLAGS
  --indent=<value>     [default: 2] Indentation depth for generated YAML files
  --lineWidth=<value>  [default: 80] Max line width for generated YAML files

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Generates YAML files for Buddy CI pipeline definitions

ALIASES
  $ buddyjs gen
  $ buddyjs g

EXAMPLES
  $ buddyjs generate

See code: src/commands/generate.ts

buddyjs help [COMMAND]

Display help for buddyjs.

USAGE
  $ buddyjs help [COMMAND...] [-n]

ARGUMENTS
  COMMAND...  Command to show help for.

FLAGS
  -n, --nested-commands  Include all nested commands in the output.

DESCRIPTION
  Display help for buddyjs.

See code: @oclif/plugin-help