Sets key in table ([] is the top of the file) to value, written as
TOML, and marks the line with # pai setup. A line it replaces stays as a
comment, so --provider off can put it back. A missing table is added at
the end of the file. The result must parse to the old file with this one
key changed.
Parameters
file: string
text: string
table: string[]
key: string
value: string
Returns string
Throws
CliErrorsetup_unreadable when the file is not valid TOML, or sets the key in a way a line edit can't change, such as an inline table or a dotted key.
Sets
keyintable([] is the top of the file) tovalue, written as TOML, and marks the line with# pai setup. A line it replaces stays as a comment, so--provider offcan put it back. A missing table is added at the end of the file. The result must parse to the old file with this one key changed.