Re: Bootstrap DATA is a pita

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: Bootstrap DATA is a pita
Дата
Msg-id 20150221100419.GJ12653@awork2.anarazel.de
обсуждение исходный текст
Ответ на Re: Bootstrap DATA is a pita  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: Bootstrap DATA is a pita  (Andrew Dunstan <andrew@dunslane.net>)
Re: Bootstrap DATA is a pita  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 2015-02-20 22:19:54 -0500, Peter Eisentraut wrote:
> On 2/20/15 8:46 PM, Josh Berkus wrote:
> > What about YAML?  That might have been added somewhat earlier.
>
> YAML isn't included in Perl, but there is
>
> Module::Build::YAML - Provides just enough YAML support so that
> Module::Build works even if YAML.pm is not installed

I'm afraid not:

sub Load {   shift if ($_[0] eq __PACKAGE__ || ref($_[0]) eq __PACKAGE__);   die "not yet implemented";
}

> > Or what about just doing CSV?
>
> I don't think that would actually address the problems.  It would just
> be the same format as now with different delimiters.

Yea, we need hierarchies and named keys.

> One concern I have with this is that in my experience different tools
> and editors have vastly different ideas on how to format these kinds of
> nested structures.  I'd try out YAML, or even a homemade fake YAML over
> this.

Yes, that's a good point. I have zero desire to open-code a format
though, I think that's a bad idea. We could say we just include
Yaml::Tiny, that's what it's made for.

To allow for changing things programatically without noise I was
wondering whether we shouldn't just load/dump the file at some point of
the build process. Then we're sure the indentation is correct and it can
be changed programatically wihtout requiring manual fixup of comments.

Greetings,

Andres Freund

--Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: POLA violation with \c service=
Следующее
От: Andres Freund
Дата:
Сообщение: Re: deparsing utility commands