BLU Discuss list archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Discuss] Application config files
- Subject: [Discuss] Application config files
- From: gaf at gapps.blu.org (Jerry Feldman)
- Date: Tue, 23 Jul 2019 15:03:55 -0400
- In-reply-to: <20190723175111.GE31101@bladeshadow.org>
- References: <5d29054d.1c69fb81.f282b.a909@mx.google.com> <20190722203320.GC31101@bladeshadow.org> <5d364689.1c69fb81.18a91.c1b9@mx.google.com> <20190723175111.GE31101@bladeshadow.org>
For my purposes, pcl would work since the user can now set everything up in the app. I have a number of true/false. Json stores them as strings. Those are simple to convert. On Tue, Jul 23, 2019, 1:52 PM Derek Martin <invalid at pizzashack.org> wrote: > On Mon, Jul 22, 2019 at 07:28:08PM -0400, Rich Pieri wrote: > > On Mon, 22 Jul 2019 15:33:20 -0500 > > Derek Martin <invalid at pizzashack.org> wrote: > > > > > But an .ini file (what we were discussing) IS easily stored in simple > > > key/value pairs, because that's exactly what it is. We were also > > > talking about Python, and it's easy enough to GUARANTEE that such a > > > simple structure is printed readibly: > > > > But we're not discussing the printing of the configuration data. > > We're discussing the storing of the configuration data in configuration > > files in ways that are both humanly editable *and* computer readable. > > JSON does not necessarily meet these two requirements. > > Effectively, printing = storing. In Unix, I/O is I/O. And given the > stated constraints, it certainly will meet those two requirements. As > long as it (or some suitable example config that can be copied) is > already formatted readibly, no human who's likely to be mucking about > with configuration data should reasonably have any difficulty editing > it. And if you're concerned about some random luser intentionally > making it difficult, which I don't imagine is a concern here, you can > just have the app rewrite the config file after it's read, ensuring > that it's well formatted. > > There are other options, and JSON/Python may not be as ideal as some > other arbitrary solution based on arbitrary criteria, but it will work > just fine for this application. > > -- > Derek D. Martin http://www.pizzashack.org/ GPG Key ID: 0xDFBEAD02 > -=-=-=-=- > This message is posted from an invalid address. Replying to it will > result in > undeliverable mail due to spam prevention. Sorry for the inconvenience. > > _______________________________________________ > Discuss mailing list > Discuss at blu.org > http://lists.blu.org/mailman/listinfo/discuss >
- References:
- [Discuss] Application config files
- From: richard.pieri at gmail.com (Rich Pieri)
- [Discuss] Application config files
- From: invalid at pizzashack.org (Derek Martin)
- [Discuss] Application config files
- From: richard.pieri at gmail.com (Rich Pieri)
- [Discuss] Application config files
- From: invalid at pizzashack.org (Derek Martin)
- [Discuss] Application config files
- Prev by Date: [Discuss] timidity
- Next by Date: [Discuss] Legacy Drivers
- Previous by thread: [Discuss] Application config files
- Next by thread: [Discuss] Application config files
- Index(es):