class Rundoc::CodeCommand
Generic CodeCommand
class to be inherited
Attributes
command[RW]
contents[RW]
keyword[RW]
original_args[RW]
render_command[RW]
render_command?[RW]
render_result[RW]
render_result?[RW]
Public Class Methods
new(*args)
click to toggle source
# File lib/rundoc/code_command.rb, line 12 def initialize(*args) end
Public Instance Methods
call(env = {})
click to toggle source
Executes command to build project Is expected to return the result of the command
# File lib/rundoc/code_command.rb, line 31 def call(env = {}) raise "not implemented on #{self.inspect}" end
push(contents)
click to toggle source
# File lib/rundoc/code_command.rb, line 23 def push(contents) @contents ||= "" @contents << contents end
Also aliased as: <<
to_md(env = {})
click to toggle source
the output of the command, i.e. `$ cat foo.txt`
# File lib/rundoc/code_command.rb, line 36 def to_md(env = {}) raise "not implemented on #{self.inspect}" end