Class: Multidocs::CLI
- Inherits:
-
Object
- Object
- Multidocs::CLI
- Defined in:
- lib/multidocs/cli.rb
Overview
command dispatcher for the multidocs executable.
Constant Summary collapse
- USAGE =
<<~TEXT multidocs #{VERSION} — kujo documentation toolchain usage: multidocs build run the rust helper binary (multidocs --version) multidocs serve serve ../public_html on http://localhost:8080 multidocs help show this message TEXT
- BINARY_CANDIDATES =
candidate locations for the rust binary, first match wins:
1. MULTIDOCS_BIN env override 2. dev build inside the repo (rust/target/release) 3. release binary dropped next to the gem 4. anything on PATH named multidocs-bin [ ENV["MULTIDOCS_BIN"], File.("../../../rust/target/release/multidocs", __dir__), File.("../../bin/multidocs-bin", __dir__), "multidocs-bin" ].compact.freeze
- DEFAULT_PORT =
8080
Instance Method Summary collapse
-
#initialize(argv) ⇒ CLI
constructor
A new instance of CLI.
- #run ⇒ Object
Constructor Details
#initialize(argv) ⇒ CLI
Returns a new instance of CLI.
35 36 37 |
# File 'lib/multidocs/cli.rb', line 35 def initialize(argv) @argv = argv end |