diff options
author | John Wiegley <johnw@newartisans.com> | 2009-11-01 21:17:53 -0500 |
---|---|---|
committer | John Wiegley <johnw@newartisans.com> | 2009-11-01 21:17:53 -0500 |
commit | 6538a2d1b8630d2a8224e517bf35ce51ab561d3a (patch) | |
tree | ce5076cbf098196055815206972579bf9b7b9d6e /src | |
parent | 39973b1277ee1655cfb82b187a9d0d523e1d5f6f (diff) | |
download | ledger-6538a2d1b8630d2a8224e517bf35ce51ab561d3a.tar.gz ledger-6538a2d1b8630d2a8224e517bf35ce51ab561d3a.tar.bz2 ledger-6538a2d1b8630d2a8224e517bf35ce51ab561d3a.zip |
Extended xact example used by some pre-commands
Diffstat (limited to 'src')
-rw-r--r-- | src/precmd.cc | 10 |
1 files 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<report_t>(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<report_t>(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; |