@arkn/breeze-cli

1.2.7 • Public • Published

Breeze logo

Breeze CLI npm (scoped)

Command line tool for Breeze content management system.

Installation

Use the package manager npm to install breeze-cli.

npm install -g @arkn/breeze-cli

Download breeze build packages from here and add them to the root of your template project.

About

The CLI provides a set of commands that helps you develop your template faster.

Supported arguments and commands

Main commands and options

Usage: breeze [options] [command]

Options:
  -V, --version  output the version number
  -h, --help     display help for command

Commands:
  create         Create template
  add            Add element to your template
  remove         Remove element from template
  build          Build your template for production
  serve          Serve your template for development

Creating a new template

To create a new template, run:

breeze create my-new-template

The breeze create command has a number of options and you can explore them all by running:

breeze create --help
Usage: create [options] <name>

Arguments:
  name               Template name

Options:
  -h, --here         Put template files on current path
  -g, --no-git-init  Disable git init
  -n, --no-npm-init  Disable npm init
  --help             display help for command

Add new section

To add new section to your template run:

Note Section identifier or SID is always convert to snake case style

breeze add section new-section 'Nouvelle section' 'New section'

You have the possibility to generate sections by applying specific models with the [ -m, --model ] argument:

breeze add section new-section -m header
List of available models
header
banner
footer
map
contact-form

You can add your custom model file here by naming it [model-name].template

The breeze add section subcommand has a number of options and you can explore them all by running:

breeze add section --help
Usage: add section [options] <sid> [name-fr] [name-en]

Arguments:
  sid                                                  Section Identifier
  name-fr                                              Section french name
  name-en                                              Section english name

Options:
  -u, --uid <uid>                                      Add section uid string
  -f, --name-fr <name-fr>                              Add section french name
  -e, --name-en <name-en>                              Add section english name
  -p, --path <path>                                    Specify the path of section component (default: "src/components/sections/")
  -P, --sections-path <sections-path>                  Specify the path of sections list (default: "sections/index.json")
  -c, --e-commerce-categories <e-commerce-categories>  Number of linked e-commerce categories (default: 0)
  -n, --news-categories <news-categories>              Number of linked news categories (default: 0)
  -x, --no-component                                   Do not add a component file
  -m, --model <model>                                  Section model (default: "default")
  -h, --help                                           display help for command

Remove section

Warning Removing sections from the breeze administration interface is more recommended as it allows you to also delete the data related to the deleted sections

To remove section from your template, run:

breeze remove section my-section

The breeze remove section subcommand has a number of options and you can explore them all by running:

breeze remove section --help
Usage: remove section [options] <sid>

Arguments:
  sid                                  Section Identifier

Options:
  -p, --path <path>                    Specify the path of section component (default: "src/components/sections/")
  -P, --sections-path <sections-path>  Specify the path of sections list (default: "sections/index.json")
  -a, --all                            Remove all linked sid
  -h, --help                           display help for command

Start development server

To serve your template during the development process, run:

breeze serve

The breeze serve command has a number of options and you can explore them all by running:

breeze serve --help
Usage: serve [options]

Options:
  -h, --host       Specify host
  -p, --port       Specify port
  --help           display help for command

Build

To build your template for production, run:

breeze build

The breeze build command has a number of options and you can explore them all by running:

breeze build --help
Usage: build [options]

Options:
  --help             display help for command

Upgrade

To upgrade your template project, run:

breeze upgrade

Warning It's recommended to commit or stash your uncommitted changes before proceeding.

You can explore breeze upgrade command by running:

breeze upgrade --help
Usage: upgrade [options]

Options:
  -f, --force  Force upgrade
  --help       display help for command

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Changelog

Detailed changes for each release are documented in the release notes.

Translations

© edPage 2022

Readme

Keywords

Package Sidebar

Install

npm i @arkn/breeze-cli

Weekly Downloads

1

Version

1.2.7

License

ISC

Unpacked Size

2.73 MB

Total Files

801

Last publish

Collaborators

  • arkn