Sha256: b18bc90cdc76c5fdcabd14062989f049d5b8080034d5762bddc2a2bf41146738
Contents?: true
Size: 525 Bytes
Versions: 8
Compression:
Stored size: 525 Bytes
Contents
require_relative 'parser' require_relative 'mathml' require_relative 'html' require_relative 'latex' module AsciiMath module CLI def self.run(args) asciimath = args.last output = '' if args.length == 1 || args.first == "mathml" output = AsciiMath.parse(asciimath).to_mathml elsif args.first == "html" output = AsciiMath.parse(asciimath).to_html elsif args.first == "latex" output = AsciiMath.parse(asciimath).to_latex end puts output end end end
Version data entries
8 entries across 8 versions & 2 rubygems