moza

0.1.2 • Public • Published

moza

styled with prettier npm version CircleCI codecov

Install

npm i -g moza
# yarn global add moza

Usage

Place *.hbs under ./.moza/ or ~/.config/moza/ directory. The contents are like this.

---
text: foo
---

<p>{{foo}}</p>

Suppose you put this as html.hbs. Then, The html command is enabled.

moza --help
# Commands:
#   html

And it is now possible to pass the text flag.

moza html --help
# Variables
#   --text

The entity of this text object is an option of yargs. When the string is set as above, it is converted as follows.

text:
 default: foo

After that, just do it like this.

moza html --text baz path/to/baz.html
# <p>baz</p>

Other commands

ls

Show enabled command list on put the local(./.moza/*.hbs). When add --global falg, global(~/.config/moza/*.hbs) command list is shown.

moza ls

add

Can fetch .hbs file from remote url. it put on local in default but this too can put on global using --global

moza add <url> --output foo.hbs

note

Show text of NOTE part of the option of Front-matter.

# baz.hbs
# ---
# NOTE: baz note
# ---
#
# <p></p>

moza note baz
# baz note

Readme

Keywords

none

Package Sidebar

Install

npm i moza

Weekly Downloads

1

Version

0.1.2

License

MIT

Last publish

Collaborators

  • nju33