@patternsoflife/patterns-cli
v1.0.0
Published
Problem-sustaining patterns CLI scripts
Readme
Patterns NodeJS CLI
This package contains command-line NodeJS scripts that invoke functionality from the patterns package.
Installation
Downloading from npmjs
The easiest way is to install this package globally on your system:
npm i -g @patternsoflife/patterns-cliThis will make the patternjs command available.
Local development
If you have the patterntools git repository checked out on your system for
local development, you can also install this package in development mode:
cd patterns-ts-cli
npm install
npm run build
npm linkThis will make the patternjs command globally available by linking it to
the bin entrypoint in your package.json. After rebuilding the package
with npm run build, the global command will reflect the changes.
Usage
Running a script
After installation you can run scripts in the following way:
patternjs <cmd> [args]Where <cmd> specifies the script to run and [args] the arguments,
if any, needed to run the script. For example:
patternjs svg mypattern.jsonGetting help
For more information about the available commands, run:
patternjs -hFor help on a specific command, run:
patternjs <cmd> -hDefinitions for SVG generator
The patternjs svg command assumes that there is a definitions directory
containing the context_categories.json, role_categories.json, and
node_definitions.json files.
