method
Fs.write_text
Fs.write_text(p, s) -> bool
Writes a string to a file, replacing any existing contents. The write is atomic — the bytes go to a temporary file that is renamed into place — so an interrupted write never corrupts the previous file. Returns true on success.
Parameters
pthe path to writesthe string contentsExample
program WriteText {
entry {
if Fs.write_text("settings.ini", "fullscreen=1") { print(1) }
}
}