Re: [HACKERS] Other formats in pset like markdown, rst, mediawiki

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: [HACKERS] Other formats in pset like markdown, rst, mediawiki
Дата
Msg-id 20170223150636.7mvaa72fyrch6pob@alvherre.pgsql
обсуждение исходный текст
Ответ на [HACKERS] Other formats in pset like markdown, rst, mediawiki  (Jan Michálek <godzilalalala@gmail.com>)
Ответы Re: [HACKERS] Other formats in pset like markdown, rst, mediawiki  (Leknín Řepánek <godzilalalala@gmail.com>)
Список pgsql-hackers
Jan Michálek wrote:

> Is there posibility, that support for some others formats will be added in
> the future? Or id posible to create some of this formats by manipulating
> with pset? Or I need use xml for export and use some xslt templates, or
> lxml etc. to create format that I will be able to copy on wiki page or in
> github issue.

I would love to have something that generates Markdown tables.  One of
the goals of psql is to make common tasks easy, and IMO generating
tables in formats commonly used in documents is one such task.

I think we discussed the idea of Markdown awhile ago, and eventually
found out that you absolutely need to align things following some crazy
rules, or the markdown processor just gives up on them.  (It works fine
for simple table contents, but if you have to escape a character
somewhere, then the alignment needs to subtract the escaping character,
or something like that)

The pandoc document http://pandoc.org/MANUAL.html#tables appears to
suggest we could use "pipe tables" to get rid of the alignment
requirement, but then the result is ugly.  It's a pity that multiline
rows don't work in that mode, also.

If you come up with code to generate good pandoc Markdown tables, I am
happy to help.

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Corey Huinker
Дата:
Сообщение: Re: [HACKERS] \if, \elseif, \else, \endif (was Re: PSQL commands:\quit_if, \quit_unless)
Следующее
От: Dilip Kumar
Дата:
Сообщение: Re: [HACKERS] Enabling parallelism for queries coming from SQL orother PL functions