Class: Chillfile::CLI
- Inherits:
-
Thor
- Object
- Thor
- Chillfile::CLI
- Defined in:
- lib/chillfile/cli.rb
Overview
CLI handles the command line interface for the ‘chillfile` binary. It is a `Thor` application.
Instance Method Summary collapse
- #dblist ⇒ Object
- #fslist ⇒ Object
-
#initialize ⇒ CLI
constructor
create a new instance with the args passed from the command line i.e.
- #sync ⇒ Object
Constructor Details
#initialize ⇒ CLI
create a new instance with the args passed from the command line i.e. ARGV
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/chillfile/cli.rb', line 31 def initialize(*) super cfg = {} cfg["path"] = [:path] cfg["couchdb_server"] = [:couchdb_server] cfg["couchdb_database"] = [:couchdb_database] cfg["couchdb_type_key"] = [:couchdb_type_key] Chillfile.boot!(cfg) if [:version] say "chillfile v#{Chillfile::VERSION}", :red exit end end |