Closed killercup closed 5 years ago
Could you elaborate on what's needed here? Do you want it to append to the file if it exists? (I'd be interested in working on this but I want to make sure I know what's wanted)
Hi! Yes, exactly. If the file exists, append to it, otherwise create it. If tried to make this a bit clearer in teh description above.
If you have any questions, don't hesitate to ask! Also, this project is in a very early stage, but I tried to write issues for things I know need to be addressed in any case.
Right now it's just calling File::create, I assume we need to use OpenOptions.
json::file("foo.log")
createsfoo.log
if it doesn't existjson::file("foo.log")
doesn't truncatefoo.log
if it does existfoo.log
exists,output::new().add_target(json::file("foo.log")?).print(text("hello world!"))
appends"hello world"
to it.