1.3.3 • Published 4 years ago

blocks-builder v1.3.3

Weekly downloads
17
License
MIT
Repository
github
Last release
4 years ago

Install

You can either install this module globally with:

npm install -g blocks-builder

or use it with npx like:

npx blocks-builder

Blocks-builder will run a npm script for every Wordpress Gutenberg plugin you specify in a given json file.

Example

Let's say you have two Gutenberg plugins, A and B. Create a JSON file in your project and put an array with the plugin name. Like this:

// example.json

["A", "B"];

Then you can run:

npx blocks-builder -f example.json -p /path/to/plugins-folder

Note that plugins folder will default to ./plugins if not specified.

Blocks-builder will now loop through the plugin directories (if existing) and by default run:

npm run build

You can change which npm script that will be run in each plugin folder. To do so you can specify a plugin as an object in the JSON file. Let's say plugin A has a build script that is called "build-plugin". We can change our JSON file to this:

// example.json

[{ "name": "A", "command": "build-plugin" }, "B"];

Options

Options:
  --help               Show help                                       [boolean]
  --version            Show version number                             [boolean]
  -f, --file           The file path to json file.           [string] [required]
  -p, --plugin-folder  The path to your plugins folder       [string] [default: "./plugins"]
1.3.3

4 years ago

1.3.2

4 years ago

1.3.1

4 years ago

1.3.0

4 years ago

1.2.1

4 years ago

1.2.0

4 years ago

1.1.0

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago