Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Microsoft.Extensions.Configuration ReadOnly?!?! Really?

So I just started looking at Microsoft.Extensions.Configuration (previously Microsoft.Framework.Configuration) as a nice and easy way to deal with INI and JSON formatted configuration files (at least that is what the extension claimed to do). But unless I'm missing something, there appears to be no way to save a configuration, at all...

You can read in configs stored as files just fine, and kinda sorta parse through sections to get to key/value pairs (there appears to be a consensus that you should have pre-knowledge of entire config, no way to really iterate through the config nicely).

But the kicker for me is there seems to be no built in method for me to update a config and save it back to disk (let alone create a default from scratch if it happened to be missing)... did I just miss something huge or is this really not there?

like image 870
Xorcist Avatar asked Sep 17 '25 03:09

Xorcist


1 Answers

Yes, persistence is not implemented, and wont be in the future.

like image 157
tm1 Avatar answered Sep 19 '25 19:09

tm1