Sha256: 5edb504a24286478e662687dcd002e1ff548e18a638b4bac75337d7454a136c5
Contents?: true
Size: 463 Bytes
Versions: 4
Compression:
Stored size: 463 Bytes
Contents
command 'schema' do |c| c.syntax = "brief schema" c.description = "view information about the schema" c.option '--all-models', 'Include all models, not just those that have documents' c.action do |args, options| schema_map = Brief.case.schema_map(options.all_models) output = if args.empty? schema_map.to_json else detail = schema_map.fetch(args.first.downcase, nil) detail.to_json if detail end output end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
brief-1.9.4 | lib/brief/cli/schema.rb |
brief-1.9.3 | lib/brief/cli/schema.rb |
brief-1.9.2 | lib/brief/cli/schema.rb |
brief-1.9.1 | lib/brief/cli/schema.rb |