Sha256: 40dc3001a9b6d909f1a957915b7661bac886ede82f2491bd0fae6e673996e2cd
Contents?: true
Size: 978 Bytes
Versions: 6
Compression:
Stored size: 978 Bytes
Contents
#!/usr/bin/env ruby help = <<-EOS MOTE(1) NAME mote -- Minimum Operational Template SYNOPSIS mote FILE [param1 value1 ... paramN valueN] DESCRIPTION Use this command line tool to render mote templates. The result is redirected to standard output. The extra parameters supplied will be passed to the template. Note that all the parameter values will be treated as strings. EXAMPLES If your template is called foo.mote, you can render it with the following command: mote foo.mote To write the result to a new file, just redirect the output: mote foo.mote > foo.html If the template uses a local variable `bar`, you can pass a value from the command line: mote foo.mote bar 42 SEE ALSO https://github.com/soveran/mote EOS if ARGV.size.even? puts help exit end t = ARGV.shift p = Hash[*ARGV] require "mote" include Mote::Helpers print mote(t, p)
Version data entries
6 entries across 6 versions & 1 rubygems
Version | Path |
---|---|
mote-1.3.1 | bin/mote |
mote-1.3.0 | bin/mote |
mote-1.2.0 | bin/mote |
mote-1.1.4 | bin/mote |
mote-1.1.3 | bin/mote |
mote-1.1.2 | bin/mote |