lib/shellplay/screen.rb in shellplay-0.0.4 vs lib/shellplay/screen.rb in shellplay-0.0.5

- old
+ new

@@ -1,31 +1,37 @@ module Shellplay class Screen - attr_reader :stdin, :stdout, :stderr, :display, :timespent, :displaycommand, :playprompt + attr_reader :stdin, :stdout, :stderr, :display, :timespent, :displaycommand, :playprompt, :clearscreen, :customprompt def initialize @displaycommand = true @playprompt = true + @clearscreen = false + @customprompt = nil @stdin = nil @stdout = nil @stderr = nil @timespent = 0 end def import(hash) @displaycommand = !!hash['displaycommand'] @playprompt = !!hash['playprompt'] + @clearscreen = !!hash['clearscreen'] + @customprompt = hash['customprompt'] @stdin = hash['stdin'] @stdout = hash['stdout'] @stderr = hash['stderr'] @timespent = hash['timespent'] end def export { displaycommand: @displaycommand, playprompt: @playprompt, + clearscreen: @clearscreen, + customprompt: @customprompt, stdin: @stdin, stdout: @stdout, stderr: @stderr, timespent: @timespent }