Class: Relaton::Cli::Command

Inherits:
Thor
  • Object
show all
Defined in:
lib/relaton/cli/command.rb

Instance Method Summary collapse

Instance Method Details

#concatenate(source_dir, outfile) ⇒ Object



28
29
30
# File 'lib/relaton/cli/command.rb', line 28

def concatenate(source_dir, outfile)
  Relaton::Cli::RelatonFile.concatenate(source_dir, outfile, options)
end

#extract(source_dir, outdir) ⇒ Object



20
21
22
# File 'lib/relaton/cli/command.rb', line 20

def extract(source_dir, outdir)
  Relaton::Cli::RelatonFile.extract(source_dir, outdir, options)
end

#fetch(code) ⇒ Object



12
13
14
15
# File 'lib/relaton/cli/command.rb', line 12

def fetch(code)
  Relaton::Cli.relaton
  say(fetch_document(code, options) || supported_type_message)
end

#xml2html(file, style, template) ⇒ Object



54
55
56
# File 'lib/relaton/cli/command.rb', line 54

def xml2html(file, style, template)
  Relaton::Cli::XMLConvertor.to_html(file, style, template)
end

#xml2yaml(filename) ⇒ Object



48
49
50
# File 'lib/relaton/cli/command.rb', line 48

def xml2yaml(filename)
  Relaton::Cli::XMLConvertor.to_yaml(filename, options)
end

#yaml2html(file, style, template) ⇒ Object



60
61
62
# File 'lib/relaton/cli/command.rb', line 60

def yaml2html(file, style, template)
  Relaton::Cli::YAMLConvertor.to_html(file, style, template)
end

#yaml2xml(filename) ⇒ Object



38
39
40
# File 'lib/relaton/cli/command.rb', line 38

def yaml2xml(filename)
  Relaton::Cli::YAMLConvertor.to_xml(filename, options)
end