Module: LiteParse::CLI

Defined in:
lib/liteparse/cli.rb

Overview

CLI support is handled by the native ‘lit` binary. Run `lit –help` from the command line for usage.

This module provides a programmatic entry point that delegates to the native CLI runner.

Examples:

LiteParse::CLI.run(["parse", "document.pdf"])

Class Method Summary collapse

Class Method Details

.run(args = ARGV) ⇒ void

This method returns an undefined value.

Run the CLI with the given arguments.

Parameters:

  • args (Array<String>) (defaults to: ARGV)

    Command-line arguments (defaults to ARGV)



18
19
20
21
22
23
# File 'lib/liteparse/cli.rb', line 18

def run(args = ARGV)
  LiteParse.run_cli(args)
rescue => e
  $stderr.puts "Error: #{e.message}"
  exit 1
end