beanquery icon indicating copy to clipboard operation
beanquery copied to clipboard

offer markdown output from beanquery

Open maxheld83 opened this issue 1 year ago • 8 comments

it would be super cool to be able to run:

bean-query --format=markdown

and then continue to convert that to whatever format you need (using pandoc or whatnot).

Formatting output is probably not a concern for beancount/beanquery, and it is possible to just take the *.csv, and convert to markdown (or whatever).

However, I can think of two reasons why formatting inside beanquery might be useful:

  • beanquery/beancount knows things about a column (data type), which is lost when saved to CSV. For example, beanquery knows that something is a currency, and should thus typically be right aligned.
  • by tapping into an external printer of tabular data (such as tabulate beancount/beanquery could offload the entire printing of tabular results (also text).

Would be great to get some feedback on whether the maintainers in principle consider this in scope for beanquery/beancount. (Because otherwise I'll hack around it to reconstruct pretty Markdown, which I'd prefer to avoid for above stated reasons).

maxheld83 avatar Feb 14 '24 18:02 maxheld83