bacure.local-save

config-file

delete-configs

(delete-configs)
Delete the configuration file for the local-device.

get-configs

(get-configs)
Get the map configs for the local device.

get-program-content

(get-program-content)(get-program-content n)
Return the string content of a program file. Nil if file doesn't
exist (or is empty).

get-program-file

(get-program-file)(get-program-file name)
Return the program file as a string.

load-program

(load-program)(load-program name)
Load a given program file. Default to 'main' if no name is given.

make-program-path

(make-program-path name)

merge-and-save-configs

(merge-and-save-configs content)
Merge the given map with the config file. Return the resulting map.

mkdir-spit

(mkdir-spit f content)
Try to make the directories leading to the file if they don't
already exists.

path

safe-read

(safe-read s)
Evaluate the string in a safe way. If error while reading, return
nil

save-and-load

(save-and-load content)(save-and-load name content)
Save and load a program string. Default to 'main' if no name is given.

save-configs

(save-configs content)
Save configs for the local device. Should be a map. Return the
configs.

set-program

(set-program content)(set-program name content)
Insert the given string into the program file. Program file default
to 'main' if not specified.