From 6538a2d1b8630d2a8224e517bf35ce51ab561d3a Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Sun, 1 Nov 2009 21:17:53 -0500 Subject: [PATCH] Extended xact example used by some pre-commands --- src/precmd.cc | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/precmd.cc b/src/precmd.cc index 590d2553..a08fd2d6 100644 --- a/src/precmd.cc +++ b/src/precmd.cc @@ -42,7 +42,7 @@ namespace ledger { namespace { - post_t * get_sample_post(report_t& report) + post_t * get_sample_xact(report_t& report) { { string str; @@ -50,7 +50,11 @@ namespace { std::ostringstream buf; buf << "2004/05/27 Book Store\n" + << " ; This note applies to all postings. :SecondTag:\n" << " Expenses:Books 20 BOOK @ $10\n" + << " ; Metadata: Some Value\n" + << " ; :ExampleTag:\n" + << " ; Here follows a note describing the posting.\n" << " Liabilities:MasterCard $-200.00\n"; str = buf.str(); @@ -82,7 +86,7 @@ value_t parse_command(call_scope_t& args) report_t& report(find_scope(args)); std::ostream& out(report.output_stream); - post_t * post = get_sample_post(report); + post_t * post = get_sample_xact(report); out << _("--- Input expression ---") << std::endl; out << arg << std::endl; @@ -131,7 +135,7 @@ value_t format_command(call_scope_t& args) report_t& report(find_scope(args)); std::ostream& out(report.output_stream); - post_t * post = get_sample_post(report); + post_t * post = get_sample_xact(report); out << _("--- Input format string ---") << std::endl; out << arg << std::endl << std::endl;