Class: Plt::CLI

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

Instance Method Summary collapse

Instance Method Details

#cat(file = nil) ⇒ Object



21
22
23
# File 'lib/plt/cli.rb', line 21

def cat(file=nil)
  puts Plt::Config.from_file(file).to_plt
end

#list(file = nil) ⇒ Object



15
16
17
18
# File 'lib/plt/cli.rb', line 15

def list(file=nil)
  puts "[RAMCELL]"
  puts Plt::Config.from_file(file).groups.flat_map(&:signals)
end

#open(file = nil) ⇒ Object



26
27
28
# File 'lib/plt/cli.rb', line 26

def open(file=nil)
  Plt::Config.from_file(file).open!
end

#show(file = nil) ⇒ Object



10
11
12
# File 'lib/plt/cli.rb', line 10

def show(file=nil)
  puts Plt::Config.from_file(file).to_s
end