Skip to content

xmlsh/mustache-cli

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mustache-cli

A CLI for mustache.java with enhanced JSON support

Building

If you dont have gradle installed the gradle wrapper (gradlew) will install gradle and all necessary components then run as if the "gradle" command were run.

Building an install

The following builds and creates an install directory in build/install/mustache-cli

Unix/Linux

sh ./gradlew installDist

Windows

gradlew installDist

Running

Include installation directory/bin in your PATH or call mustache-cli explicitly

build/install/mustache-cli or mustache-cli

Note that the default run script generated by gradle is quite verbose in order to be environment agnostic. You can edit it or create a new one sets the classspath and invokes the Main class org.xmlsh.tools.mustache.cli.main.Main

java -cp <lib/*> org.xmlsh.tools.mustache.cli.main.Main [ options ]

Usage:

mustache-cli [options]

Options

Option Arg Description
--root | -R | --template-dir dirname Template directory root
-f | --template-file filename Template file or '-'
-t | --template | --template-data 'text' Template data inline
-p | --properties-file filename Context read from Java properties file"
-j | --json-data filename Context inline as JSON"
-J | --json-file filename Context read from JSON file"
-o | --output | --output-file filename Write to output file or '-'"
-n | --name filename Template name
-S | --delim-start "string" Delmitar start string [default '{{']
-E | --delim-end dirname Delmitar end string [default '}}']
--json Use JSON encoded data for variable expansion
--html Use HTML encoded data for variable expansion
-h | --help Help

Other build tasks

Supports the common gradle tasks for application, java etc. run

gradle :tasks for a list of tasks or

gradle --help

for a list of options.

gradle distTar # creates a tar distribution

gradle distZip # creates a zip distribution

See hhttp://gradle.org/docs/current/userguide/userguide.html for common gradle usage

About

A CLI for justache.java

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages