persist LCD too
This commit is contained in:
parent
0da1ab8590
commit
7773007fc3
2 changed files with 8 additions and 1 deletions
|
@ -37,7 +37,7 @@ class Rpl < Interpreter
|
|||
def persist_state
|
||||
return if @persistence_filename.nil?
|
||||
|
||||
File.write(@persistence_filename, "#{export_vars}\n#{export_stack}")
|
||||
File.write(@persistence_filename, "#{export_lcd}\n#{export_vars}\n#{export_stack}")
|
||||
end
|
||||
|
||||
def run!( input )
|
||||
|
|
|
@ -77,6 +77,13 @@ class Interpreter
|
|||
args
|
||||
end
|
||||
|
||||
def export_lcd
|
||||
lcd_as_string = "@ LCD:\n"
|
||||
lcd_as_string += "#{@lcd_grob} →lcd\n"
|
||||
|
||||
lcd_as_string
|
||||
end
|
||||
|
||||
def export_vars
|
||||
vars_as_string = "@ variables:\n"
|
||||
vars_as_string += @dictionary.vars
|
||||
|
|
Loading…
Reference in a new issue