Merge branch 'next'
This commit is contained in:
commit
f3bedb88b2
64 changed files with 784 additions and 510 deletions
22
acprep
22
acprep
|
|
@ -357,7 +357,7 @@ class CommandLineApp(object):
|
||||||
exit_code = self.handleMainException()
|
exit_code = self.handleMainException()
|
||||||
if self.options.debug:
|
if self.options.debug:
|
||||||
raise
|
raise
|
||||||
|
|
||||||
if self.force_exit:
|
if self.force_exit:
|
||||||
sys.exit(exit_code)
|
sys.exit(exit_code)
|
||||||
return exit_code
|
return exit_code
|
||||||
|
|
@ -376,6 +376,7 @@ class PrepareBuild(CommandLineApp):
|
||||||
self.current_ver = None
|
self.current_ver = None
|
||||||
#self.current_flavor = 'default'
|
#self.current_flavor = 'default'
|
||||||
self.current_flavor = 'debug'
|
self.current_flavor = 'debug'
|
||||||
|
self.prefix_dir = None
|
||||||
self.products_dir = None
|
self.products_dir = None
|
||||||
self.build_dir = self.source_dir
|
self.build_dir = self.source_dir
|
||||||
self.configure_args = ['--with-included-gettext', '--enable-python']
|
self.configure_args = ['--with-included-gettext', '--enable-python']
|
||||||
|
|
@ -502,6 +503,9 @@ class PrepareBuild(CommandLineApp):
|
||||||
op.add_option('', '--pic', action="callback",
|
op.add_option('', '--pic', action="callback",
|
||||||
callback=self.option_pic,
|
callback=self.option_pic,
|
||||||
help='Compile with explicit PIC support')
|
help='Compile with explicit PIC support')
|
||||||
|
op.add_option('', '--prefix', metavar='DIR', action="callback",
|
||||||
|
callback=self.option_prefix, type="string",
|
||||||
|
help='Use custom installation prefix')
|
||||||
op.add_option('', '--products', metavar='DIR', action="callback",
|
op.add_option('', '--products', metavar='DIR', action="callback",
|
||||||
callback=self.option_products,
|
callback=self.option_products,
|
||||||
help='Collect all build products in this directory')
|
help='Collect all build products in this directory')
|
||||||
|
|
@ -584,6 +588,12 @@ class PrepareBuild(CommandLineApp):
|
||||||
# Determine information about the surroundings #
|
# Determine information about the surroundings #
|
||||||
#########################################################################
|
#########################################################################
|
||||||
|
|
||||||
|
def prefix_directory(self):
|
||||||
|
if self.prefix_dir:
|
||||||
|
return self.prefix_dir
|
||||||
|
else:
|
||||||
|
return None
|
||||||
|
|
||||||
def default_products_directory(self):
|
def default_products_directory(self):
|
||||||
if self.envvars['LEDGER_PRODUCTS']:
|
if self.envvars['LEDGER_PRODUCTS']:
|
||||||
return self.envvars['LEDGER_PRODUCTS']
|
return self.envvars['LEDGER_PRODUCTS']
|
||||||
|
|
@ -665,6 +675,8 @@ class PrepareBuild(CommandLineApp):
|
||||||
self.log.info("Source directory => " + self.source_dir)
|
self.log.info("Source directory => " + self.source_dir)
|
||||||
self.log.info("Need to run autogen.sh => " +
|
self.log.info("Need to run autogen.sh => " +
|
||||||
str(self.need_to_prepare_autotools()))
|
str(self.need_to_prepare_autotools()))
|
||||||
|
if self.prefix_directory():
|
||||||
|
self.log.info("Installation prefix => " + self.prefix_directory())
|
||||||
self.log.info("Products directory => " + self.products_directory())
|
self.log.info("Products directory => " + self.products_directory())
|
||||||
self.log.info("Build directory => " + self.build_directory())
|
self.log.info("Build directory => " + self.build_directory())
|
||||||
self.log.info("Need to run configure => " +
|
self.log.info("Need to run configure => " +
|
||||||
|
|
@ -1163,6 +1175,10 @@ class PrepareBuild(CommandLineApp):
|
||||||
self.log.debug('Saw option --output')
|
self.log.debug('Saw option --output')
|
||||||
self.build_dir = value
|
self.build_dir = value
|
||||||
|
|
||||||
|
def option_prefix(self, option=None, opt_str=None, value=None, parser=None):
|
||||||
|
self.log.debug('Saw option --prefix')
|
||||||
|
self.prefix_dir = value
|
||||||
|
|
||||||
def option_products(self, option=None, opt_str=None, value=None, parser=None):
|
def option_products(self, option=None, opt_str=None, value=None, parser=None):
|
||||||
self.log.debug('Saw option --products')
|
self.log.debug('Saw option --products')
|
||||||
self.products_dir = value
|
self.products_dir = value
|
||||||
|
|
@ -1320,6 +1336,9 @@ class PrepareBuild(CommandLineApp):
|
||||||
conf_args.append('--with-boost-suffix=%s' %
|
conf_args.append('--with-boost-suffix=%s' %
|
||||||
self.boost_info.get_suffix())
|
self.boost_info.get_suffix())
|
||||||
|
|
||||||
|
if self.prefix_directory():
|
||||||
|
conf_args.append('--prefix=%s' % self.prefix_directory())
|
||||||
|
|
||||||
return (environ, conf_args + self.configure_args)
|
return (environ, conf_args + self.configure_args)
|
||||||
|
|
||||||
def need_to_run_configure(self):
|
def need_to_run_configure(self):
|
||||||
|
|
@ -1514,6 +1533,7 @@ class PrepareBuild(CommandLineApp):
|
||||||
self.build_dir = None # use the build/ tree
|
self.build_dir = None # use the build/ tree
|
||||||
self.current_flavor = flavor
|
self.current_flavor = flavor
|
||||||
self.option_release()
|
self.option_release()
|
||||||
|
self.prefix_dir = None
|
||||||
|
|
||||||
if reset and exists(self.build_directory()) and \
|
if reset and exists(self.build_directory()) and \
|
||||||
isdir(self.build_directory()):
|
isdir(self.build_directory()):
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,26 @@
|
||||||
(defvar ledger-sample-doc-path "/Users/johnw/src/ledger/doc/sample.dat")
|
(defvar ledger-sample-doc-path "/Users/johnw/src/ledger/doc/sample.dat")
|
||||||
(defvar ledger-normalization-args "--args-only --columns 80")
|
(defvar ledger-normalization-args "--args-only --columns 80")
|
||||||
|
|
||||||
|
(defun ledger-update-test ()
|
||||||
|
(interactive)
|
||||||
|
(goto-char (point-min))
|
||||||
|
(let ((command (buffer-substring (point-min) (line-end-position)))
|
||||||
|
input)
|
||||||
|
(re-search-forward "^<<<\n")
|
||||||
|
(let ((beg (point)) end)
|
||||||
|
(re-search-forward "^>>>")
|
||||||
|
(setq end (match-beginning 0))
|
||||||
|
(forward-line 1)
|
||||||
|
(let ((output-beg (point)))
|
||||||
|
(re-search-forward "^>>>")
|
||||||
|
(goto-char (match-beginning 0))
|
||||||
|
(delete-region output-beg (point))
|
||||||
|
(apply #'call-process-region
|
||||||
|
beg end (expand-file-name "~/Products/ledger/debug/ledger")
|
||||||
|
nil t nil
|
||||||
|
"-f" "-" "--args-only" "--columns=80" "--no-color"
|
||||||
|
(split-string command " "))))))
|
||||||
|
|
||||||
(defun ledger-texi-write-test (name command input output &optional category)
|
(defun ledger-texi-write-test (name command input output &optional category)
|
||||||
(let ((buf (current-buffer)))
|
(let ((buf (current-buffer)))
|
||||||
(with-current-buffer (find-file-noselect
|
(with-current-buffer (find-file-noselect
|
||||||
|
|
|
||||||
|
|
@ -67,8 +67,8 @@ assert not 'CAD' in comms
|
||||||
# want all amounts to default to the European-style, set the static variable
|
# want all amounts to default to the European-style, set the static variable
|
||||||
# `european_by_default'.
|
# `european_by_default'.
|
||||||
|
|
||||||
eur.add_flags(ledger.COMMODITY_STYLE_EUROPEAN)
|
eur.add_flags(ledger.COMMODITY_STYLE_DECIMAL_COMMA)
|
||||||
assert eur.has_flags(ledger.COMMODITY_STYLE_EUROPEAN)
|
assert eur.has_flags(ledger.COMMODITY_STYLE_DECIMAL_COMMA)
|
||||||
assert not eur.has_flags(ledger.COMMODITY_STYLE_THOUSANDS)
|
assert not eur.has_flags(ledger.COMMODITY_STYLE_THOUSANDS)
|
||||||
|
|
||||||
comms.european_by_default = True
|
comms.european_by_default = True
|
||||||
|
|
|
||||||
|
|
@ -295,7 +295,7 @@ namespace {
|
||||||
|
|
||||||
foreach (post_t * p, account.posts) {
|
foreach (post_t * p, account.posts) {
|
||||||
bind_scope_t bound_scope(args, *p);
|
bind_scope_t bound_scope(args, *p);
|
||||||
if (expr->calc(bound_scope).to_boolean())
|
if (expr->calc(bound_scope, args.locus, args.depth).to_boolean())
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
|
@ -308,7 +308,7 @@ namespace {
|
||||||
|
|
||||||
foreach (post_t * p, account.posts) {
|
foreach (post_t * p, account.posts) {
|
||||||
bind_scope_t bound_scope(args, *p);
|
bind_scope_t bound_scope(args, *p);
|
||||||
if (! expr->calc(bound_scope).to_boolean())
|
if (! expr->calc(bound_scope, args.locus, args.depth).to_boolean())
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
|
||||||
|
|
@ -646,9 +646,13 @@ void commodity_t::print(std::ostream& out, bool elide_quotes) const
|
||||||
{
|
{
|
||||||
string sym = symbol();
|
string sym = symbol();
|
||||||
if (elide_quotes && has_flags(COMMODITY_STYLE_SEPARATED) &&
|
if (elide_quotes && has_flags(COMMODITY_STYLE_SEPARATED) &&
|
||||||
! sym.empty() && sym[0] == '"' && ! std::strchr(sym.c_str(), ' ')) {
|
! sym.empty() && sym[0] == '"' &&
|
||||||
DEBUG("foo", "contracting " << sym << " to " << string(sym, 1, sym.length() - 2));
|
! std::strchr(sym.c_str(), ' ')) {
|
||||||
out << string(sym, 1, sym.length() - 2);
|
string subsym(sym, 1, sym.length() - 2);
|
||||||
|
if (! all(subsym, is_digit()))
|
||||||
|
out << subsym;
|
||||||
|
else
|
||||||
|
out << sym;
|
||||||
} else
|
} else
|
||||||
out << sym;
|
out << sym;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -501,26 +501,15 @@ void related_posts::flush()
|
||||||
{
|
{
|
||||||
if (posts.size() > 0) {
|
if (posts.size() > 0) {
|
||||||
foreach (post_t * post, posts) {
|
foreach (post_t * post, posts) {
|
||||||
if (post->xact) {
|
assert(post->xact);
|
||||||
foreach (post_t * r_post, post->xact->posts) {
|
foreach (post_t * r_post, post->xact->posts) {
|
||||||
post_t::xdata_t& xdata(r_post->xdata());
|
post_t::xdata_t& xdata(r_post->xdata());
|
||||||
if (! xdata.has_flags(POST_EXT_HANDLED) &&
|
|
||||||
(! xdata.has_flags(POST_EXT_RECEIVED) ?
|
|
||||||
! r_post->has_flags(ITEM_GENERATED | POST_VIRTUAL) :
|
|
||||||
also_matching)) {
|
|
||||||
xdata.add_flags(POST_EXT_HANDLED);
|
|
||||||
item_handler<post_t>::operator()(*r_post);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
// This code should only be reachable from the "output"
|
|
||||||
// command, since that is the only command which attempts to
|
|
||||||
// output auto or period xacts.
|
|
||||||
post_t::xdata_t& xdata(post->xdata());
|
|
||||||
if (! xdata.has_flags(POST_EXT_HANDLED) &&
|
if (! xdata.has_flags(POST_EXT_HANDLED) &&
|
||||||
! post->has_flags(ITEM_GENERATED)) {
|
(! xdata.has_flags(POST_EXT_RECEIVED) ?
|
||||||
|
! r_post->has_flags(ITEM_GENERATED | POST_VIRTUAL) :
|
||||||
|
also_matching)) {
|
||||||
xdata.add_flags(POST_EXT_HANDLED);
|
xdata.add_flags(POST_EXT_HANDLED);
|
||||||
item_handler<post_t>::operator()(*post);
|
item_handler<post_t>::operator()(*r_post);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1228,18 +1217,16 @@ void budget_posts::operator()(post_t& post)
|
||||||
|
|
||||||
void forecast_posts::add_post(const date_interval_t& period, post_t& post)
|
void forecast_posts::add_post(const date_interval_t& period, post_t& post)
|
||||||
{
|
{
|
||||||
generate_posts::add_post(period, post);
|
date_interval_t i(period);
|
||||||
|
if (! i.start && ! i.find_period(CURRENT_DATE()))
|
||||||
|
return;
|
||||||
|
|
||||||
// Advance the period's interval until it is at or beyond the current date.
|
generate_posts::add_post(i, post);
|
||||||
date_interval_t& i = pending_posts.back().first;
|
|
||||||
if (! i.start) {
|
// Advance the period's interval until it is at or beyond the current
|
||||||
if (! i.find_period(CURRENT_DATE()))
|
// date.
|
||||||
throw_(std::runtime_error, _("Something odd has happened"));
|
while (*i.start < CURRENT_DATE())
|
||||||
++i;
|
++i;
|
||||||
} else {
|
|
||||||
while (*i.start < CURRENT_DATE())
|
|
||||||
++i;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void forecast_posts::flush()
|
void forecast_posts::flush()
|
||||||
|
|
@ -1281,6 +1268,8 @@ void forecast_posts::flush()
|
||||||
for (pending_posts_list::iterator i = ++pending_posts.begin();
|
for (pending_posts_list::iterator i = ++pending_posts.begin();
|
||||||
i != pending_posts.end();
|
i != pending_posts.end();
|
||||||
i++) {
|
i++) {
|
||||||
|
assert((*i).first.start);
|
||||||
|
assert((*least).first.start);
|
||||||
if (*(*i).first.start < *(*least).first.start)
|
if (*(*i).first.start < *(*least).first.start)
|
||||||
least = i;
|
least = i;
|
||||||
}
|
}
|
||||||
|
|
@ -1307,7 +1296,6 @@ void forecast_posts::flush()
|
||||||
}
|
}
|
||||||
|
|
||||||
begin = next;
|
begin = next;
|
||||||
++(*least).first;
|
|
||||||
|
|
||||||
// `post' refers to the posting defined in the period transaction. We
|
// `post' refers to the posting defined in the period transaction. We
|
||||||
// make a copy of it within a temporary transaction with the payee
|
// make a copy of it within a temporary transaction with the payee
|
||||||
|
|
@ -1337,6 +1325,14 @@ void forecast_posts::flush()
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Increment the 'least', but remove it from pending_posts if it
|
||||||
|
// exceeds its own boundaries.
|
||||||
|
++(*least).first;
|
||||||
|
if (! (*least).first.start) {
|
||||||
|
pending_posts.erase(least);
|
||||||
|
continue;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
item_handler<post_t>::flush();
|
item_handler<post_t>::flush();
|
||||||
|
|
|
||||||
153
src/format.cc
153
src/format.cc
|
|
@ -432,6 +432,23 @@ string format_t::truncate(const unistring& ustr,
|
||||||
|
|
||||||
case ABBREVIATE:
|
case ABBREVIATE:
|
||||||
if (account_abbrev_length > 0) {
|
if (account_abbrev_length > 0) {
|
||||||
|
// The algorithm here is complex, but aims to preserve the most
|
||||||
|
// information in the most useful places.
|
||||||
|
//
|
||||||
|
// Consider: You have an account name like
|
||||||
|
// 'Assets:Banking:Check:Register'. This account name, which is
|
||||||
|
// 29 characters long, must be shortened to fit in 20. How would
|
||||||
|
// you shorten it?
|
||||||
|
//
|
||||||
|
// The approach taken below is to compute the difference, or 9
|
||||||
|
// characters, and then distribute this difference semi-evenly
|
||||||
|
// among first three segments of the account name, by taking
|
||||||
|
// characters until the difference is gone. Further, earlier
|
||||||
|
// segments will give up more of their share of letters than later
|
||||||
|
// segments, since the later segments usually contain more useful
|
||||||
|
// information.
|
||||||
|
|
||||||
|
// First, chop up the Unicode string into individual segments.
|
||||||
std::list<string> parts;
|
std::list<string> parts;
|
||||||
string::size_type beg = 0;
|
string::size_type beg = 0;
|
||||||
string strcopy(ustr.extract());
|
string strcopy(ustr.extract());
|
||||||
|
|
@ -441,34 +458,140 @@ string format_t::truncate(const unistring& ustr,
|
||||||
parts.push_back(string(strcopy, beg, pos - beg));
|
parts.push_back(string(strcopy, beg, pos - beg));
|
||||||
parts.push_back(string(strcopy, beg));
|
parts.push_back(string(strcopy, beg));
|
||||||
|
|
||||||
std::ostringstream result;
|
DEBUG("format.abbrev", "Account name: " << strcopy);
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"Must fit a " << len << " char string in " << width << " chars");
|
||||||
|
|
||||||
std::size_t newlen = len;
|
// Figure out the lengths of all the parts. The last part is
|
||||||
|
// always displayed in full, while the former parts are
|
||||||
|
// distributed, with the latter parts being longer than the
|
||||||
|
// former, but with none shorter than account_abbrev_length.
|
||||||
|
std::list<std::size_t> lens;
|
||||||
|
#if defined(DEBUG_ON)
|
||||||
|
int index = 0;
|
||||||
|
#endif
|
||||||
for (std::list<string>::iterator i = parts.begin();
|
for (std::list<string>::iterator i = parts.begin();
|
||||||
i != parts.end();
|
i != parts.end();
|
||||||
i++) {
|
i++) {
|
||||||
// Don't contract the last element
|
std::size_t l = unistring(*i).length();
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"Segment " << ++index << " is " << l << " chars wide");
|
||||||
|
lens.push_back(l);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Determine the "overflow", or how many chars in excess we are.
|
||||||
|
|
||||||
|
std::size_t overflow = len - width;
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"There are " << overflow << " chars of overflow");
|
||||||
|
|
||||||
|
// Walk through the first n-1 segments, and start subtracting
|
||||||
|
// letters to decrease the overflow. This is done in multiple
|
||||||
|
// passes until the overflow is gone, or we cannot reduce any
|
||||||
|
// further. The calculation to find the amount to remove is:
|
||||||
|
//
|
||||||
|
// overflow * (((len(segment) + counter) * iteration) /
|
||||||
|
// (len(string) - len(last_segment) - counter))
|
||||||
|
//
|
||||||
|
// Where:
|
||||||
|
// overflow - the amount that needs to be removed
|
||||||
|
// counter - starts at n-1 for the first segment, then
|
||||||
|
// decreases by one until it reaches 0 for the
|
||||||
|
// last segment (which is never shortened).
|
||||||
|
// This value is used to weight the shrinkage
|
||||||
|
// so that earlier segments shrink faster.
|
||||||
|
// iteration - starts at 1, increase by 1 for every
|
||||||
|
// iteration of the loop
|
||||||
|
//
|
||||||
|
// In the example above, we have this account name:
|
||||||
|
//
|
||||||
|
// Assets:Banking:Check:Register
|
||||||
|
//
|
||||||
|
// Therefore, the amount to be removed from Assets is calculated as:
|
||||||
|
//
|
||||||
|
// 9 * (((6 + 3) * 1) / (29 - 8 - 3)) = ceil(4.5) = 5
|
||||||
|
//
|
||||||
|
// However, since removing 5 chars would make the length of the
|
||||||
|
// segment shorter than the default minimum of 2, we can only
|
||||||
|
// remove 4 chars from Assets to reduce the overflow. And on it
|
||||||
|
// goes.
|
||||||
|
//
|
||||||
|
// The final result will be: As:Ban:Chec:Register
|
||||||
|
|
||||||
|
std::size_t iteration = 1;
|
||||||
|
std::size_t len_minus_last = len - lens.back();
|
||||||
|
while (overflow > 0) {
|
||||||
|
std::size_t overflow_at_start = overflow;
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"Overflow starting at " << overflow << " chars");
|
||||||
|
#if defined(DEBUG_ON)
|
||||||
|
index = 0;
|
||||||
|
#endif
|
||||||
|
std::size_t counter = lens.size();
|
||||||
|
for (std::list<std::size_t>::iterator i = lens.begin();
|
||||||
|
i != lens.end();
|
||||||
|
i++) {
|
||||||
|
if (--counter == 0 || overflow == 0)
|
||||||
|
break;
|
||||||
|
DEBUG("format.abbrev", "Overflow is " << overflow << " chars");
|
||||||
|
std::size_t adjust;
|
||||||
|
if (overflow == 1)
|
||||||
|
adjust = 1;
|
||||||
|
else
|
||||||
|
adjust = std::size_t
|
||||||
|
(std::ceil(double(overflow) *
|
||||||
|
((double(*i + counter) * double(iteration)) /
|
||||||
|
(double(len_minus_last) - double(counter)))));
|
||||||
|
DEBUG("format.abbrev", "Weight calc: (" << overflow
|
||||||
|
<< " * (((" << *i << " + " << counter << ") * "
|
||||||
|
<< iteration << ") / (" << len_minus_last
|
||||||
|
<< " - " << counter << ")))");
|
||||||
|
if (adjust == 0)
|
||||||
|
adjust = 1;
|
||||||
|
else if (adjust > overflow)
|
||||||
|
adjust = overflow;
|
||||||
|
DEBUG("format.abbrev", "The weighted part is " << adjust << " chars");
|
||||||
|
std::size_t slack = *i - std::min(*i, account_abbrev_length);
|
||||||
|
if (adjust > slack)
|
||||||
|
adjust = slack;
|
||||||
|
if (adjust > 0) {
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"Reducing segment " << ++index << " by " << adjust << " chars");
|
||||||
|
(*i) -= adjust;
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"Segment " << index << " is now " << *i << " chars wide");
|
||||||
|
overflow -= adjust;
|
||||||
|
DEBUG("format.abbrev", "Overflow is now " << overflow << " chars");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
DEBUG("format.abbrev",
|
||||||
|
"Overflow ending this time at " << overflow << " chars");
|
||||||
|
if (overflow == overflow_at_start)
|
||||||
|
break;
|
||||||
|
iteration++;
|
||||||
|
}
|
||||||
|
|
||||||
|
assert(parts.size() == lens.size());
|
||||||
|
|
||||||
|
std::list<string>::iterator i = parts.begin();
|
||||||
|
std::list<std::size_t>::iterator l = lens.begin();
|
||||||
|
std::ostringstream result;
|
||||||
|
|
||||||
|
for (; i != parts.end() && l != lens.end(); i++, l++) {
|
||||||
std::list<string>::iterator x = i;
|
std::list<string>::iterator x = i;
|
||||||
if (++x == parts.end()) {
|
if (++x == parts.end()) {
|
||||||
result << *i;
|
result << *i;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (newlen > width) {
|
unistring temp(*i);
|
||||||
unistring temp(*i);
|
if (temp.length() > *l)
|
||||||
if (temp.length() > account_abbrev_length) {
|
result << temp.extract(0, *l) << ":";
|
||||||
result << temp.extract(0, account_abbrev_length) << ":";
|
else
|
||||||
newlen -= temp.length() - account_abbrev_length;
|
|
||||||
} else {
|
|
||||||
result << temp.extract() << ":";
|
|
||||||
newlen -= temp.length();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
result << *i << ":";
|
result << *i << ":";
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (newlen > width) {
|
if (overflow > 0) {
|
||||||
// Even abbreviated its too big to show the last account, so
|
// Even abbreviated its too big to show the last account, so
|
||||||
// abbreviate all but the last and truncate at the beginning.
|
// abbreviate all but the last and truncate at the beginning.
|
||||||
unistring temp(result.str());
|
unistring temp(result.str());
|
||||||
|
|
|
||||||
|
|
@ -49,6 +49,8 @@ global_scope_t::global_scope_t(char ** envp)
|
||||||
{
|
{
|
||||||
TRACE_CTOR(global_scope_t, "");
|
TRACE_CTOR(global_scope_t, "");
|
||||||
|
|
||||||
|
epoch = CURRENT_TIME();
|
||||||
|
|
||||||
#if defined(HAVE_BOOST_PYTHON)
|
#if defined(HAVE_BOOST_PYTHON)
|
||||||
if (! python_session.get()) {
|
if (! python_session.get()) {
|
||||||
python_session.reset(new ledger::python_interpreter_t);
|
python_session.reset(new ledger::python_interpreter_t);
|
||||||
|
|
|
||||||
20
src/item.cc
20
src/item.cc
|
|
@ -134,10 +134,9 @@ item_t::set_tag(const string& tag,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void item_t::parse_tags(const char * p,
|
void item_t::parse_tags(const char * p,
|
||||||
scope_t& scope,
|
scope_t& scope,
|
||||||
bool overwrite_existing,
|
bool overwrite_existing)
|
||||||
optional<date_t::year_type> current_year)
|
|
||||||
{
|
{
|
||||||
if (const char * b = std::strchr(p, '[')) {
|
if (const char * b = std::strchr(p, '[')) {
|
||||||
if (*(b + 1) != '\0' &&
|
if (*(b + 1) != '\0' &&
|
||||||
|
|
@ -149,10 +148,10 @@ void item_t::parse_tags(const char * p,
|
||||||
|
|
||||||
if (char * p = std::strchr(buf, '=')) {
|
if (char * p = std::strchr(buf, '=')) {
|
||||||
*p++ = '\0';
|
*p++ = '\0';
|
||||||
_date_eff = parse_date(p, current_year);
|
_date_eff = parse_date(p);
|
||||||
}
|
}
|
||||||
if (buf[0])
|
if (buf[0])
|
||||||
_date = parse_date(buf, current_year);
|
_date = parse_date(buf);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -202,10 +201,9 @@ void item_t::parse_tags(const char * p,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void item_t::append_note(const char * p,
|
void item_t::append_note(const char * p,
|
||||||
scope_t& scope,
|
scope_t& scope,
|
||||||
bool overwrite_existing,
|
bool overwrite_existing)
|
||||||
optional<date_t::year_type> current_year)
|
|
||||||
{
|
{
|
||||||
if (note) {
|
if (note) {
|
||||||
*note += '\n';
|
*note += '\n';
|
||||||
|
|
@ -214,7 +212,7 @@ void item_t::append_note(const char * p,
|
||||||
note = p;
|
note = p;
|
||||||
}
|
}
|
||||||
|
|
||||||
parse_tags(p, scope, overwrite_existing, current_year);
|
parse_tags(p, scope, overwrite_existing);
|
||||||
}
|
}
|
||||||
|
|
||||||
namespace {
|
namespace {
|
||||||
|
|
|
||||||
14
src/item.h
14
src/item.h
|
|
@ -162,14 +162,12 @@ public:
|
||||||
const optional<value_t>& value = none,
|
const optional<value_t>& value = none,
|
||||||
const bool overwrite_existing = true);
|
const bool overwrite_existing = true);
|
||||||
|
|
||||||
virtual void parse_tags(const char * p,
|
virtual void parse_tags(const char * p,
|
||||||
scope_t& scope,
|
scope_t& scope,
|
||||||
bool overwrite_existing = true,
|
bool overwrite_existing = true);
|
||||||
optional<date_t::year_type> current_year = none);
|
virtual void append_note(const char * p,
|
||||||
virtual void append_note(const char * p,
|
scope_t& scope,
|
||||||
scope_t& scope,
|
bool overwrite_existing = true);
|
||||||
bool overwrite_existing = true,
|
|
||||||
optional<date_t::year_type> current_year = none);
|
|
||||||
|
|
||||||
static bool use_effective_date;
|
static bool use_effective_date;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -105,8 +105,7 @@ account_t * journal_t::find_account_re(const string& regexp)
|
||||||
return master->find_account_re(regexp);
|
return master->find_account_re(regexp);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool journal_t::add_xact(xact_t * xact,
|
bool journal_t::add_xact(xact_t * xact)
|
||||||
optional<date_t::year_type> current_year)
|
|
||||||
{
|
{
|
||||||
xact->journal = this;
|
xact->journal = this;
|
||||||
|
|
||||||
|
|
@ -115,17 +114,16 @@ bool journal_t::add_xact(xact_t * xact,
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
extend_xact(xact, current_year);
|
extend_xact(xact);
|
||||||
xacts.push_back(xact);
|
xacts.push_back(xact);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void journal_t::extend_xact(xact_base_t * xact,
|
void journal_t::extend_xact(xact_base_t * xact)
|
||||||
optional<date_t::year_type> current_year)
|
|
||||||
{
|
{
|
||||||
foreach (auto_xact_t * auto_xact, auto_xacts)
|
foreach (auto_xact_t * auto_xact, auto_xacts)
|
||||||
auto_xact->extend_xact(*xact, current_year);
|
auto_xact->extend_xact(*xact);
|
||||||
}
|
}
|
||||||
|
|
||||||
bool journal_t::remove_xact(xact_t * xact)
|
bool journal_t::remove_xact(xact_t * xact)
|
||||||
|
|
|
||||||
|
|
@ -140,10 +140,8 @@ public:
|
||||||
account_t * find_account(const string& name, bool auto_create = true);
|
account_t * find_account(const string& name, bool auto_create = true);
|
||||||
account_t * find_account_re(const string& regexp);
|
account_t * find_account_re(const string& regexp);
|
||||||
|
|
||||||
bool add_xact(xact_t * xact,
|
bool add_xact(xact_t * xact);
|
||||||
optional<date_t::year_type> current_year = none);
|
void extend_xact(xact_base_t * xact);
|
||||||
void extend_xact(xact_base_t * xact,
|
|
||||||
optional<date_t::year_type> current_year = none);
|
|
||||||
bool remove_xact(xact_t * xact);
|
bool remove_xact(xact_t * xact);
|
||||||
|
|
||||||
xacts_list::iterator xacts_begin() {
|
xacts_list::iterator xacts_begin() {
|
||||||
|
|
|
||||||
|
|
@ -157,7 +157,7 @@ value_t expr_t::op_t::calc(scope_t& scope, ptr_op_t * locus, const int depth)
|
||||||
// Evaluating an identifier is the same as calling its definition
|
// Evaluating an identifier is the same as calling its definition
|
||||||
// directly, so we create an empty call_scope_t to reflect the scope for
|
// directly, so we create an empty call_scope_t to reflect the scope for
|
||||||
// this implicit call.
|
// this implicit call.
|
||||||
call_scope_t call_args(scope, scope.type_context(), scope.type_required());
|
call_scope_t call_args(scope, locus, depth);
|
||||||
result = left()->compile(call_args, depth + 1)
|
result = left()->compile(call_args, depth + 1)
|
||||||
->calc(call_args, locus, depth + 1);
|
->calc(call_args, locus, depth + 1);
|
||||||
check_type_context(scope, result);
|
check_type_context(scope, result);
|
||||||
|
|
@ -168,7 +168,7 @@ value_t expr_t::op_t::calc(scope_t& scope, ptr_op_t * locus, const int depth)
|
||||||
// Evaluating a FUNCTION is the same as calling it directly; this happens
|
// Evaluating a FUNCTION is the same as calling it directly; this happens
|
||||||
// when certain functions-that-look-like-variables (such as "amount") are
|
// when certain functions-that-look-like-variables (such as "amount") are
|
||||||
// resolved.
|
// resolved.
|
||||||
call_scope_t call_args(scope, scope.type_context(), scope.type_required());
|
call_scope_t call_args(scope, locus, depth);
|
||||||
result = as_function()(call_args);
|
result = as_function()(call_args);
|
||||||
check_type_context(scope, result);
|
check_type_context(scope, result);
|
||||||
#if defined(DEBUG_ON)
|
#if defined(DEBUG_ON)
|
||||||
|
|
@ -235,7 +235,7 @@ value_t expr_t::op_t::calc(scope_t& scope, ptr_op_t * locus, const int depth)
|
||||||
}
|
}
|
||||||
|
|
||||||
case O_CALL: {
|
case O_CALL: {
|
||||||
call_scope_t call_args(scope, scope.type_context(), scope.type_required());
|
call_scope_t call_args(scope, locus, depth);
|
||||||
if (has_right())
|
if (has_right())
|
||||||
call_args.set_args(split_cons_expr(right()->kind == O_SEQ ?
|
call_args.set_args(split_cons_expr(right()->kind == O_SEQ ?
|
||||||
right()->left() : right()));
|
right()->left() : right()));
|
||||||
|
|
|
||||||
12
src/post.cc
12
src/post.cc
|
|
@ -353,12 +353,14 @@ namespace {
|
||||||
foreach (post_t * p, post.xact->posts) {
|
foreach (post_t * p, post.xact->posts) {
|
||||||
bind_scope_t bound_scope(args, *p);
|
bind_scope_t bound_scope(args, *p);
|
||||||
if (p == &post && args.has<expr_t::ptr_op_t>(1) &&
|
if (p == &post && args.has<expr_t::ptr_op_t>(1) &&
|
||||||
! args.get<expr_t::ptr_op_t>(1)->calc(bound_scope).to_boolean()) {
|
! args.get<expr_t::ptr_op_t>(1)
|
||||||
|
->calc(bound_scope, args.locus, args.depth).to_boolean()) {
|
||||||
// If the user specifies any(EXPR, false), and the context is a
|
// If the user specifies any(EXPR, false), and the context is a
|
||||||
// posting, then that posting isn't considered by the test.
|
// posting, then that posting isn't considered by the test.
|
||||||
; // skip it
|
; // skip it
|
||||||
}
|
}
|
||||||
else if (expr->calc(bound_scope).to_boolean()) {
|
else if (expr->calc(bound_scope, args.locus,
|
||||||
|
args.depth).to_boolean()) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -373,12 +375,14 @@ namespace {
|
||||||
foreach (post_t * p, post.xact->posts) {
|
foreach (post_t * p, post.xact->posts) {
|
||||||
bind_scope_t bound_scope(args, *p);
|
bind_scope_t bound_scope(args, *p);
|
||||||
if (p == &post && args.has<expr_t::ptr_op_t>(1) &&
|
if (p == &post && args.has<expr_t::ptr_op_t>(1) &&
|
||||||
! args.get<expr_t::ptr_op_t>(1)->calc(bound_scope).to_boolean()) {
|
! args.get<expr_t::ptr_op_t>(1)
|
||||||
|
->calc(bound_scope, args.locus, args.depth).to_boolean()) {
|
||||||
// If the user specifies any(EXPR, false), and the context is a
|
// If the user specifies any(EXPR, false), and the context is a
|
||||||
// posting, then that posting isn't considered by the test.
|
// posting, then that posting isn't considered by the test.
|
||||||
; // skip it
|
; // skip it
|
||||||
}
|
}
|
||||||
else if (! expr->calc(bound_scope).to_boolean()) {
|
else if (! expr->calc(bound_scope, args.locus,
|
||||||
|
args.depth).to_boolean()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -186,7 +186,7 @@ value_t period_command(call_scope_t& args)
|
||||||
out << std::endl;
|
out << std::endl;
|
||||||
|
|
||||||
date_interval_t interval(arg);
|
date_interval_t interval(arg);
|
||||||
interval.dump(out, report.session.current_year);
|
interval.dump(out);
|
||||||
|
|
||||||
return NULL_VALUE;
|
return NULL_VALUE;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -148,8 +148,8 @@ void report_t::normalize_options(const string& verb)
|
||||||
if (HANDLED(period_)) {
|
if (HANDLED(period_)) {
|
||||||
date_interval_t interval(HANDLER(period_).str());
|
date_interval_t interval(HANDLER(period_).str());
|
||||||
|
|
||||||
optional<date_t> begin = interval.begin(session.current_year);
|
optional<date_t> begin = interval.begin();
|
||||||
optional<date_t> end = interval.end(session.current_year);
|
optional<date_t> end = interval.end();
|
||||||
|
|
||||||
if (! HANDLED(begin_) && begin) {
|
if (! HANDLED(begin_) && begin) {
|
||||||
string predicate = "date>=[" + to_iso_extended_string(*begin) + "]";
|
string predicate = "date>=[" + to_iso_extended_string(*begin) + "]";
|
||||||
|
|
|
||||||
10
src/report.h
10
src/report.h
|
|
@ -393,7 +393,7 @@ public:
|
||||||
|
|
||||||
OPTION_(report_t, begin_, DO_(args) { // -b
|
OPTION_(report_t, begin_, DO_(args) { // -b
|
||||||
date_interval_t interval(args.get<string>(1));
|
date_interval_t interval(args.get<string>(1));
|
||||||
optional<date_t> begin = interval.begin(parent->session.current_year);
|
optional<date_t> begin = interval.begin();
|
||||||
if (! begin)
|
if (! begin)
|
||||||
throw_(std::invalid_argument,
|
throw_(std::invalid_argument,
|
||||||
_("Could not determine beginning of period '%1'")
|
_("Could not determine beginning of period '%1'")
|
||||||
|
|
@ -543,8 +543,9 @@ public:
|
||||||
OPTION_(report_t, end_, DO_(args) { // -e
|
OPTION_(report_t, end_, DO_(args) { // -e
|
||||||
date_interval_t interval(args.get<string>(1));
|
date_interval_t interval(args.get<string>(1));
|
||||||
// Use begin() here so that if the user says --end=2008, we end on
|
// Use begin() here so that if the user says --end=2008, we end on
|
||||||
// 2008/01/01 instead of 2009/01/01 (which is what end() would return).
|
// 2008/01/01 instead of 2009/01/01 (which is what end() would
|
||||||
optional<date_t> end = interval.begin(parent->session.current_year);
|
// return).
|
||||||
|
optional<date_t> end = interval.begin();
|
||||||
if (! end)
|
if (! end)
|
||||||
throw_(std::invalid_argument,
|
throw_(std::invalid_argument,
|
||||||
_("Could not determine end of period '%1'")
|
_("Could not determine end of period '%1'")
|
||||||
|
|
@ -665,13 +666,12 @@ public:
|
||||||
|
|
||||||
OPTION_(report_t, now_, DO_(args) {
|
OPTION_(report_t, now_, DO_(args) {
|
||||||
date_interval_t interval(args.get<string>(1));
|
date_interval_t interval(args.get<string>(1));
|
||||||
optional<date_t> begin = interval.begin(parent->session.current_year);
|
optional<date_t> begin = interval.begin();
|
||||||
if (! begin)
|
if (! begin)
|
||||||
throw_(std::invalid_argument,
|
throw_(std::invalid_argument,
|
||||||
_("Could not determine beginning of period '%1'")
|
_("Could not determine beginning of period '%1'")
|
||||||
<< args.get<string>(1));
|
<< args.get<string>(1));
|
||||||
ledger::epoch = parent->terminus = datetime_t(*begin);
|
ledger::epoch = parent->terminus = datetime_t(*begin);
|
||||||
parent->session.current_year = ledger::epoch->date().year();
|
|
||||||
});
|
});
|
||||||
|
|
||||||
OPTION__
|
OPTION__
|
||||||
|
|
|
||||||
|
|
@ -81,7 +81,7 @@ value_t& call_scope_t::resolve(const std::size_t index,
|
||||||
value_t& value(args[index]);
|
value_t& value(args[index]);
|
||||||
if (value.is_any()) {
|
if (value.is_any()) {
|
||||||
context_scope_t scope(*this, context, required);
|
context_scope_t scope(*this, context, required);
|
||||||
value = as_expr(value)->calc(scope);
|
value = as_expr(value)->calc(scope, locus, depth);
|
||||||
if (required && ! value.is_type(context))
|
if (required && ! value.is_type(context))
|
||||||
throw_(calc_error, _("Expected %1 for argument %2, but received %3")
|
throw_(calc_error, _("Expected %1 for argument %2, but received %3")
|
||||||
<< value.label(context) << index
|
<< value.label(context) << index
|
||||||
|
|
|
||||||
16
src/scope.h
16
src/scope.h
|
|
@ -335,11 +335,17 @@ class call_scope_t : public context_scope_t
|
||||||
const bool required = false);
|
const bool required = false);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit call_scope_t(scope_t& _parent,
|
expr_t::ptr_op_t * locus;
|
||||||
value_t::type_t _type_context = value_t::VOID,
|
const int depth;
|
||||||
const bool _required = true)
|
|
||||||
: context_scope_t(_parent, _type_context, _required), ptr(NULL) {
|
explicit call_scope_t(scope_t& _parent,
|
||||||
TRACE_CTOR(call_scope_t, "scope_t&, value_t::type_t, bool");
|
expr_t::ptr_op_t * _locus = NULL,
|
||||||
|
const int _depth = 0)
|
||||||
|
: context_scope_t(_parent, _parent.type_context(),
|
||||||
|
_parent.type_required()),
|
||||||
|
ptr(NULL), locus(_locus), depth(_depth) {
|
||||||
|
TRACE_CTOR(call_scope_t,
|
||||||
|
"scope_t&, value_t::type_t, bool, expr_t::ptr_op_t *, int");
|
||||||
}
|
}
|
||||||
virtual ~call_scope_t() {
|
virtual ~call_scope_t() {
|
||||||
TRACE_DTOR(call_scope_t);
|
TRACE_DTOR(call_scope_t);
|
||||||
|
|
|
||||||
|
|
@ -60,9 +60,7 @@ void set_session_context(session_t * session)
|
||||||
}
|
}
|
||||||
|
|
||||||
session_t::session_t()
|
session_t::session_t()
|
||||||
: flush_on_next_data_file(false),
|
: flush_on_next_data_file(false), journal(new journal_t)
|
||||||
current_year(CURRENT_DATE().year()),
|
|
||||||
journal(new journal_t)
|
|
||||||
{
|
{
|
||||||
TRACE_CTOR(session_t, "");
|
TRACE_CTOR(session_t, "");
|
||||||
|
|
||||||
|
|
@ -192,6 +190,40 @@ value_t session_t::fn_account(call_scope_t& args)
|
||||||
return NULL_VALUE;
|
return NULL_VALUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
value_t session_t::fn_min(call_scope_t& args)
|
||||||
|
{
|
||||||
|
return args[1] < args[0] ? args[1] : args[0];
|
||||||
|
}
|
||||||
|
value_t session_t::fn_max(call_scope_t& args)
|
||||||
|
{
|
||||||
|
return args[1] > args[0] ? args[1] : args[0];
|
||||||
|
}
|
||||||
|
|
||||||
|
value_t session_t::fn_lot_price(call_scope_t& args)
|
||||||
|
{
|
||||||
|
amount_t amt(args.get<amount_t>(1, false));
|
||||||
|
if (amt.has_annotation() && amt.annotation().price)
|
||||||
|
return *amt.annotation().price;
|
||||||
|
else
|
||||||
|
return NULL_VALUE;
|
||||||
|
}
|
||||||
|
value_t session_t::fn_lot_date(call_scope_t& args)
|
||||||
|
{
|
||||||
|
amount_t amt(args.get<amount_t>(1, false));
|
||||||
|
if (amt.has_annotation() && amt.annotation().date)
|
||||||
|
return *amt.annotation().date;
|
||||||
|
else
|
||||||
|
return NULL_VALUE;
|
||||||
|
}
|
||||||
|
value_t session_t::fn_lot_tag(call_scope_t& args)
|
||||||
|
{
|
||||||
|
amount_t amt(args.get<amount_t>(1, false));
|
||||||
|
if (amt.has_annotation() && amt.annotation().tag)
|
||||||
|
return string_value(*amt.annotation().tag);
|
||||||
|
else
|
||||||
|
return NULL_VALUE;
|
||||||
|
}
|
||||||
|
|
||||||
option_t<session_t> * session_t::lookup_option(const char * p)
|
option_t<session_t> * session_t::lookup_option(const char * p)
|
||||||
{
|
{
|
||||||
switch (*p) {
|
switch (*p) {
|
||||||
|
|
@ -243,6 +275,23 @@ expr_t::ptr_op_t session_t::lookup(const symbol_t::kind_t kind,
|
||||||
if (is_eq(p, "account"))
|
if (is_eq(p, "account"))
|
||||||
return MAKE_FUNCTOR(session_t::fn_account);
|
return MAKE_FUNCTOR(session_t::fn_account);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 'l':
|
||||||
|
if (is_eq(p, "lot_price"))
|
||||||
|
return MAKE_FUNCTOR(session_t::fn_lot_price);
|
||||||
|
else if (is_eq(p, "lot_date"))
|
||||||
|
return MAKE_FUNCTOR(session_t::fn_lot_date);
|
||||||
|
else if (is_eq(p, "lot_tag"))
|
||||||
|
return MAKE_FUNCTOR(session_t::fn_lot_tag);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 'm':
|
||||||
|
if (is_eq(p, "min"))
|
||||||
|
return MAKE_FUNCTOR(session_t::fn_min);
|
||||||
|
else if (is_eq(p, "max"))
|
||||||
|
return MAKE_FUNCTOR(session_t::fn_max);
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -56,8 +56,7 @@ class session_t : public symbol_scope_t
|
||||||
friend void set_session_context(session_t * session);
|
friend void set_session_context(session_t * session);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
bool flush_on_next_data_file;
|
bool flush_on_next_data_file;
|
||||||
date_t::year_type current_year;
|
|
||||||
std::auto_ptr<journal_t> journal;
|
std::auto_ptr<journal_t> journal;
|
||||||
|
|
||||||
explicit session_t();
|
explicit session_t();
|
||||||
|
|
@ -75,6 +74,11 @@ public:
|
||||||
void close_journal_files();
|
void close_journal_files();
|
||||||
|
|
||||||
value_t fn_account(call_scope_t& scope);
|
value_t fn_account(call_scope_t& scope);
|
||||||
|
value_t fn_min(call_scope_t& scope);
|
||||||
|
value_t fn_max(call_scope_t& scope);
|
||||||
|
value_t fn_lot_price(call_scope_t& scope);
|
||||||
|
value_t fn_lot_date(call_scope_t& scope);
|
||||||
|
value_t fn_lot_tag(call_scope_t& scope);
|
||||||
|
|
||||||
void report_options(std::ostream& out)
|
void report_options(std::ostream& out)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -93,18 +93,17 @@ namespace {
|
||||||
static const std::size_t MAX_LINE = 1024;
|
static const std::size_t MAX_LINE = 1024;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
parse_context_t& context;
|
parse_context_t& context;
|
||||||
instance_t * parent;
|
instance_t * parent;
|
||||||
accounts_map account_aliases;
|
accounts_map account_aliases;
|
||||||
const path * original_file;
|
const path * original_file;
|
||||||
path pathname;
|
path pathname;
|
||||||
std::istream& in;
|
std::istream& in;
|
||||||
char linebuf[MAX_LINE + 1];
|
char linebuf[MAX_LINE + 1];
|
||||||
std::size_t linenum;
|
std::size_t linenum;
|
||||||
istream_pos_type line_beg_pos;
|
istream_pos_type line_beg_pos;
|
||||||
istream_pos_type curr_pos;
|
istream_pos_type curr_pos;
|
||||||
|
optional<datetime_t> prev_epoch;
|
||||||
optional<date_t::year_type> current_year;
|
|
||||||
|
|
||||||
instance_t(parse_context_t& _context,
|
instance_t(parse_context_t& _context,
|
||||||
std::istream& _in,
|
std::istream& _in,
|
||||||
|
|
@ -207,11 +206,15 @@ instance_t::instance_t(parse_context_t& _context,
|
||||||
pathname(original_file ? *original_file : "/dev/stdin"), in(_in)
|
pathname(original_file ? *original_file : "/dev/stdin"), in(_in)
|
||||||
{
|
{
|
||||||
TRACE_CTOR(instance_t, "...");
|
TRACE_CTOR(instance_t, "...");
|
||||||
|
DEBUG("times.epoch", "Saving epoch " << epoch);
|
||||||
|
prev_epoch = epoch; // declared in times.h
|
||||||
}
|
}
|
||||||
|
|
||||||
instance_t::~instance_t()
|
instance_t::~instance_t()
|
||||||
{
|
{
|
||||||
TRACE_DTOR(instance_t);
|
TRACE_DTOR(instance_t);
|
||||||
|
epoch = prev_epoch;
|
||||||
|
DEBUG("times.epoch", "Restored epoch to " << epoch);
|
||||||
}
|
}
|
||||||
|
|
||||||
void instance_t::parse()
|
void instance_t::parse()
|
||||||
|
|
@ -420,7 +423,7 @@ void instance_t::clock_in_directive(char * line, bool /*capitalized*/)
|
||||||
position.end_line = linenum;
|
position.end_line = linenum;
|
||||||
position.sequence = context.sequence++;
|
position.sequence = context.sequence++;
|
||||||
|
|
||||||
time_xact_t event(position, parse_datetime(datetime, current_year),
|
time_xact_t event(position, parse_datetime(datetime),
|
||||||
p ? context.top_account()->find_account(p) : NULL,
|
p ? context.top_account()->find_account(p) : NULL,
|
||||||
n ? n : "",
|
n ? n : "",
|
||||||
end ? end : "");
|
end ? end : "");
|
||||||
|
|
@ -449,7 +452,7 @@ void instance_t::clock_out_directive(char * line, bool /*capitalized*/)
|
||||||
position.end_line = linenum;
|
position.end_line = linenum;
|
||||||
position.sequence = context.sequence++;
|
position.sequence = context.sequence++;
|
||||||
|
|
||||||
time_xact_t event(position, parse_datetime(datetime, current_year),
|
time_xact_t event(position, parse_datetime(datetime),
|
||||||
p ? context.top_account()->find_account(p) : NULL,
|
p ? context.top_account()->find_account(p) : NULL,
|
||||||
n ? n : "",
|
n ? n : "",
|
||||||
end ? end : "");
|
end ? end : "");
|
||||||
|
|
@ -503,7 +506,12 @@ void instance_t::nomarket_directive(char * line)
|
||||||
|
|
||||||
void instance_t::year_directive(char * line)
|
void instance_t::year_directive(char * line)
|
||||||
{
|
{
|
||||||
current_year = lexical_cast<unsigned short>(skip_ws(line + 1));
|
unsigned short year(lexical_cast<unsigned short>(skip_ws(line + 1)));
|
||||||
|
DEBUG("times.epoch", "Setting current year to " << year);
|
||||||
|
// This must be set to the last day of the year, otherwise partial
|
||||||
|
// dates like "11/01" will refer to last year's november, not the
|
||||||
|
// current year.
|
||||||
|
epoch = datetime_t(date_t(year, 12, 31));
|
||||||
}
|
}
|
||||||
|
|
||||||
void instance_t::option_directive(char * line)
|
void instance_t::option_directive(char * line)
|
||||||
|
|
@ -554,7 +562,7 @@ void instance_t::automated_xact_directive(char * line)
|
||||||
item = ae.get();
|
item = ae.get();
|
||||||
|
|
||||||
// This is a trailing note, and possibly a metadata info tag
|
// This is a trailing note, and possibly a metadata info tag
|
||||||
item->append_note(p + 1, context.scope, true, current_year);
|
item->append_note(p + 1, context.scope, true);
|
||||||
item->pos->end_pos = curr_pos;
|
item->pos->end_pos = curr_pos;
|
||||||
item->pos->end_line++;
|
item->pos->end_line++;
|
||||||
|
|
||||||
|
|
@ -634,7 +642,7 @@ void instance_t::period_xact_directive(char * line)
|
||||||
pe->journal = &context.journal;
|
pe->journal = &context.journal;
|
||||||
|
|
||||||
if (pe->finalize()) {
|
if (pe->finalize()) {
|
||||||
context.journal.extend_xact(pe.get(), current_year);
|
context.journal.extend_xact(pe.get());
|
||||||
context.journal.period_xacts.push_back(pe.get());
|
context.journal.period_xacts.push_back(pe.get());
|
||||||
|
|
||||||
pe->pos->end_pos = curr_pos;
|
pe->pos->end_pos = curr_pos;
|
||||||
|
|
@ -885,14 +893,14 @@ void instance_t::assert_directive(char * line)
|
||||||
{
|
{
|
||||||
expr_t expr(line);
|
expr_t expr(line);
|
||||||
if (! expr.calc(context.scope).to_boolean())
|
if (! expr.calc(context.scope).to_boolean())
|
||||||
throw_(parse_error, _("Assertion failed: %1" << line));
|
throw_(parse_error, _("Assertion failed: %1") << line);
|
||||||
}
|
}
|
||||||
|
|
||||||
void instance_t::check_directive(char * line)
|
void instance_t::check_directive(char * line)
|
||||||
{
|
{
|
||||||
expr_t expr(line);
|
expr_t expr(line);
|
||||||
if (! expr.calc(context.scope).to_boolean())
|
if (! expr.calc(context.scope).to_boolean())
|
||||||
warning_(_("Check failed: %1" << line));
|
warning_(_("Check failed: %1") << line);
|
||||||
}
|
}
|
||||||
|
|
||||||
void instance_t::expr_directive(char * line)
|
void instance_t::expr_directive(char * line)
|
||||||
|
|
@ -1324,7 +1332,7 @@ post_t * instance_t::parse_post(char * line,
|
||||||
// Parse the optional note
|
// Parse the optional note
|
||||||
|
|
||||||
if (next && *next == ';') {
|
if (next && *next == ';') {
|
||||||
post->append_note(++next, context.scope, true, current_year);
|
post->append_note(++next, context.scope, true);
|
||||||
next = line + len;
|
next = line + len;
|
||||||
DEBUG("textual.parse", "line " << linenum << ": "
|
DEBUG("textual.parse", "line " << linenum << ": "
|
||||||
<< "Parsed a posting note");
|
<< "Parsed a posting note");
|
||||||
|
|
@ -1343,8 +1351,7 @@ post_t * instance_t::parse_post(char * line,
|
||||||
if (! context.state_stack.empty()) {
|
if (! context.state_stack.empty()) {
|
||||||
foreach (const state_t& state, context.state_stack)
|
foreach (const state_t& state, context.state_stack)
|
||||||
if (state.type() == typeid(string))
|
if (state.type() == typeid(string))
|
||||||
post->parse_tags(boost::get<string>(state).c_str(), context.scope,
|
post->parse_tags(boost::get<string>(state).c_str(), context.scope, true);
|
||||||
true, current_year);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE_STOP(post_details, 1);
|
TRACE_STOP(post_details, 1);
|
||||||
|
|
@ -1407,9 +1414,9 @@ xact_t * instance_t::parse_xact(char * line,
|
||||||
|
|
||||||
if (char * p = std::strchr(line, '=')) {
|
if (char * p = std::strchr(line, '=')) {
|
||||||
*p++ = '\0';
|
*p++ = '\0';
|
||||||
xact->_date_eff = parse_date(p, current_year);
|
xact->_date_eff = parse_date(p);
|
||||||
}
|
}
|
||||||
xact->_date = parse_date(line, current_year);
|
xact->_date = parse_date(line);
|
||||||
|
|
||||||
// Parse the optional cleared flag: *
|
// Parse the optional cleared flag: *
|
||||||
|
|
||||||
|
|
@ -1456,7 +1463,7 @@ xact_t * instance_t::parse_xact(char * line,
|
||||||
// Parse the xact note
|
// Parse the xact note
|
||||||
|
|
||||||
if (next && *next == ';')
|
if (next && *next == ';')
|
||||||
xact->append_note(++next, context.scope, false, current_year);
|
xact->append_note(++next, context.scope, false);
|
||||||
|
|
||||||
TRACE_STOP(xact_text, 1);
|
TRACE_STOP(xact_text, 1);
|
||||||
|
|
||||||
|
|
@ -1483,7 +1490,7 @@ xact_t * instance_t::parse_xact(char * line,
|
||||||
|
|
||||||
if (*p == ';') {
|
if (*p == ';') {
|
||||||
// This is a trailing note, and possibly a metadata info tag
|
// This is a trailing note, and possibly a metadata info tag
|
||||||
item->append_note(p + 1, context.scope, true, current_year);
|
item->append_note(p + 1, context.scope, true);
|
||||||
item->pos->end_pos = curr_pos;
|
item->pos->end_pos = curr_pos;
|
||||||
item->pos->end_line++;
|
item->pos->end_line++;
|
||||||
}
|
}
|
||||||
|
|
@ -1502,9 +1509,9 @@ xact_t * instance_t::parse_xact(char * line,
|
||||||
}
|
}
|
||||||
else if (! expr.calc(bound_scope).to_boolean()) {
|
else if (! expr.calc(bound_scope).to_boolean()) {
|
||||||
if (c == 'a') {
|
if (c == 'a') {
|
||||||
throw_(parse_error, _("Transaction assertion failed: %1" << p));
|
throw_(parse_error, _("Transaction assertion failed: %1") << p);
|
||||||
} else {
|
} else {
|
||||||
warning_(_("Transaction check failed: %1" << p));
|
warning_(_("Transaction check failed: %1") << p);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1542,7 +1549,7 @@ xact_t * instance_t::parse_xact(char * line,
|
||||||
foreach (const state_t& state, context.state_stack)
|
foreach (const state_t& state, context.state_stack)
|
||||||
if (state.type() == typeid(string))
|
if (state.type() == typeid(string))
|
||||||
xact->parse_tags(boost::get<string>(state).c_str(), context.scope,
|
xact->parse_tags(boost::get<string>(state).c_str(), context.scope,
|
||||||
false, current_year);
|
false);
|
||||||
}
|
}
|
||||||
|
|
||||||
TRACE_STOP(xact_details, 1);
|
TRACE_STOP(xact_details, 1);
|
||||||
|
|
|
||||||
159
src/times.cc
159
src/times.cc
|
|
@ -194,7 +194,6 @@ namespace {
|
||||||
std::deque<shared_ptr<date_io_t> > readers;
|
std::deque<shared_ptr<date_io_t> > readers;
|
||||||
|
|
||||||
date_t parse_date_mask_routine(const char * date_str, date_io_t& io,
|
date_t parse_date_mask_routine(const char * date_str, date_io_t& io,
|
||||||
optional_year year,
|
|
||||||
date_traits_t * traits = NULL)
|
date_traits_t * traits = NULL)
|
||||||
{
|
{
|
||||||
VERIFY(std::strlen(date_str) < 127);
|
VERIFY(std::strlen(date_str) < 127);
|
||||||
|
|
@ -229,29 +228,26 @@ namespace {
|
||||||
*traits = io.traits;
|
*traits = io.traits;
|
||||||
|
|
||||||
if (! io.traits.has_year) {
|
if (! io.traits.has_year) {
|
||||||
when = date_t(year ? *year : CURRENT_DATE().year(),
|
when = date_t(CURRENT_DATE().year(), when.month(), when.day());
|
||||||
when.month(), when.day());
|
|
||||||
|
|
||||||
if (! year && when.month() > CURRENT_DATE().month())
|
if (when.month() > CURRENT_DATE().month())
|
||||||
when -= gregorian::years(1);
|
when -= gregorian::years(1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return when;
|
return when;
|
||||||
}
|
}
|
||||||
|
|
||||||
date_t parse_date_mask(const char * date_str, optional_year year,
|
date_t parse_date_mask(const char * date_str, date_traits_t * traits = NULL)
|
||||||
date_traits_t * traits = NULL)
|
|
||||||
{
|
{
|
||||||
if (input_date_io.get()) {
|
if (input_date_io.get()) {
|
||||||
date_t when = parse_date_mask_routine(date_str, *input_date_io.get(),
|
date_t when = parse_date_mask_routine(date_str, *input_date_io.get(),
|
||||||
year, traits);
|
traits);
|
||||||
if (! when.is_not_a_date())
|
if (! when.is_not_a_date())
|
||||||
return when;
|
return when;
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach (shared_ptr<date_io_t>& reader, readers) {
|
foreach (shared_ptr<date_io_t>& reader, readers) {
|
||||||
date_t when = parse_date_mask_routine(date_str, *reader.get(),
|
date_t when = parse_date_mask_routine(date_str, *reader.get(), traits);
|
||||||
year, traits);
|
|
||||||
if (! when.is_not_a_date())
|
if (! when.is_not_a_date())
|
||||||
return when;
|
return when;
|
||||||
}
|
}
|
||||||
|
|
@ -312,7 +308,7 @@ string_to_month_of_year(const std::string& str)
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
|
|
||||||
datetime_t parse_datetime(const char * str, optional_year)
|
datetime_t parse_datetime(const char * str)
|
||||||
{
|
{
|
||||||
datetime_t when = input_datetime_io->parse(str);
|
datetime_t when = input_datetime_io->parse(str);
|
||||||
if (when.is_not_a_date_time())
|
if (when.is_not_a_date_time())
|
||||||
|
|
@ -320,18 +316,16 @@ datetime_t parse_datetime(const char * str, optional_year)
|
||||||
return when;
|
return when;
|
||||||
}
|
}
|
||||||
|
|
||||||
date_t parse_date(const char * str, optional_year current_year)
|
date_t parse_date(const char * str)
|
||||||
{
|
{
|
||||||
return parse_date_mask(str, current_year);
|
return parse_date_mask(str);
|
||||||
}
|
}
|
||||||
|
|
||||||
date_t date_specifier_t::begin(const optional_year& current_year) const
|
date_t date_specifier_t::begin() const
|
||||||
{
|
{
|
||||||
assert(year || current_year);
|
year_type the_year = year ? *year : year_type(CURRENT_DATE().year());
|
||||||
|
|
||||||
year_type the_year = year ? *year : static_cast<year_type>(*current_year);
|
|
||||||
month_type the_month = month ? *month : date_t::month_type(1);
|
month_type the_month = month ? *month : date_t::month_type(1);
|
||||||
day_type the_day = day ? *day : date_t::day_type(1);
|
day_type the_day = day ? *day : date_t::day_type(1);
|
||||||
|
|
||||||
#if !defined(NO_ASSERTS)
|
#if !defined(NO_ASSERTS)
|
||||||
if (day)
|
if (day)
|
||||||
|
|
@ -348,14 +342,14 @@ date_t date_specifier_t::begin(const optional_year& current_year) const
|
||||||
static_cast<date_t::day_type>(the_day));
|
static_cast<date_t::day_type>(the_day));
|
||||||
}
|
}
|
||||||
|
|
||||||
date_t date_specifier_t::end(const optional_year& current_year) const
|
date_t date_specifier_t::end() const
|
||||||
{
|
{
|
||||||
if (day || wday)
|
if (day || wday)
|
||||||
return begin(current_year) + gregorian::days(1);
|
return begin() + gregorian::days(1);
|
||||||
else if (month)
|
else if (month)
|
||||||
return begin(current_year) + gregorian::months(1);
|
return begin() + gregorian::months(1);
|
||||||
else if (year)
|
else if (year)
|
||||||
return begin(current_year) + gregorian::years(1);
|
return begin() + gregorian::years(1);
|
||||||
else {
|
else {
|
||||||
assert(false);
|
assert(false);
|
||||||
return date_t();
|
return date_t();
|
||||||
|
|
@ -667,6 +661,16 @@ void date_parser_t::determine_when(date_parser_t::lexer_t::token_t& tok,
|
||||||
(boost::get<date_time::weekdays>(*tok.value));
|
(boost::get<date_time::weekdays>(*tok.value));
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case lexer_t::token_t::TOK_TODAY:
|
||||||
|
specifier = date_specifier_t(CURRENT_DATE());
|
||||||
|
break;
|
||||||
|
case lexer_t::token_t::TOK_TOMORROW:
|
||||||
|
specifier = date_specifier_t(CURRENT_DATE() + gregorian::days(1));
|
||||||
|
break;
|
||||||
|
case lexer_t::token_t::TOK_YESTERDAY:
|
||||||
|
specifier = date_specifier_t(CURRENT_DATE() - gregorian::days(1));
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
tok.unexpected();
|
tok.unexpected();
|
||||||
break;
|
break;
|
||||||
|
|
@ -687,14 +691,6 @@ date_interval_t date_parser_t::parse()
|
||||||
tok.kind != lexer_t::token_t::END_REACHED;
|
tok.kind != lexer_t::token_t::END_REACHED;
|
||||||
tok = lexer.next_token()) {
|
tok = lexer.next_token()) {
|
||||||
switch (tok.kind) {
|
switch (tok.kind) {
|
||||||
#if 0
|
|
||||||
case lexer_t::token_t::TOK_INT:
|
|
||||||
// jww (2009-11-18): NYI
|
|
||||||
assert(! "Need to allow for expressions like \"4 months ago\"");
|
|
||||||
tok.unexpected();
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
case lexer_t::token_t::TOK_DATE:
|
case lexer_t::token_t::TOK_DATE:
|
||||||
if (! inclusion_specifier)
|
if (! inclusion_specifier)
|
||||||
inclusion_specifier = date_specifier_t();
|
inclusion_specifier = date_specifier_t();
|
||||||
|
|
@ -782,11 +778,44 @@ date_interval_t date_parser_t::parse()
|
||||||
|
|
||||||
tok = lexer.next_token();
|
tok = lexer.next_token();
|
||||||
switch (tok.kind) {
|
switch (tok.kind) {
|
||||||
case lexer_t::token_t::TOK_INT:
|
case lexer_t::token_t::TOK_INT: {
|
||||||
// jww (2009-11-18): Allow things like "last 5 weeks"
|
unsigned short amount = boost::get<unsigned short>(*tok.value);
|
||||||
assert(! "Need to allow for expressions like \"last 5 weeks\"");
|
|
||||||
tok.unexpected();
|
date_t base(today);
|
||||||
|
date_t end(today);
|
||||||
|
|
||||||
|
tok = lexer.next_token();
|
||||||
|
switch (tok.kind) {
|
||||||
|
case lexer_t::token_t::TOK_YEARS:
|
||||||
|
base += gregorian::years(amount * adjust);
|
||||||
|
break;
|
||||||
|
case lexer_t::token_t::TOK_QUARTERS:
|
||||||
|
base += gregorian::months(amount * adjust * 3);
|
||||||
|
break;
|
||||||
|
case lexer_t::token_t::TOK_MONTHS:
|
||||||
|
base += gregorian::months(amount * adjust);
|
||||||
|
break;
|
||||||
|
case lexer_t::token_t::TOK_WEEKS:
|
||||||
|
base += gregorian::weeks(amount * adjust);
|
||||||
|
break;
|
||||||
|
case lexer_t::token_t::TOK_DAYS:
|
||||||
|
base += gregorian::days(amount * adjust);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
tok.unexpected();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (adjust >= 0) {
|
||||||
|
date_t temp = base;
|
||||||
|
base = end;
|
||||||
|
end = temp;
|
||||||
|
}
|
||||||
|
|
||||||
|
since_specifier = date_specifier_t(base);
|
||||||
|
until_specifier = date_specifier_t(end);
|
||||||
break;
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
case lexer_t::token_t::TOK_A_MONTH: {
|
case lexer_t::token_t::TOK_A_MONTH: {
|
||||||
inclusion_specifier = date_specifier_t();
|
inclusion_specifier = date_specifier_t();
|
||||||
|
|
@ -822,26 +851,40 @@ date_interval_t date_parser_t::parse()
|
||||||
}
|
}
|
||||||
|
|
||||||
case lexer_t::token_t::TOK_QUARTER: {
|
case lexer_t::token_t::TOK_QUARTER: {
|
||||||
date_t temp =
|
date_t base =
|
||||||
date_duration_t::find_nearest(today, date_duration_t::QUARTERS);
|
date_duration_t::find_nearest(today, date_duration_t::QUARTERS);
|
||||||
temp += gregorian::months(3 * adjust);
|
date_t temp;
|
||||||
inclusion_specifier =
|
if (adjust < 0) {
|
||||||
date_specifier_t(static_cast<date_specifier_t::year_type>(temp.year()),
|
temp = base + gregorian::months(3 * adjust);
|
||||||
temp.month());
|
}
|
||||||
#if 0
|
else if (adjust == 0) {
|
||||||
period.duration = date_duration_t(date_duration_t::QUARTERS, 1);
|
temp = base + gregorian::months(3);
|
||||||
#endif
|
}
|
||||||
|
else if (adjust > 0) {
|
||||||
|
base += gregorian::months(3 * adjust);
|
||||||
|
temp = base + gregorian::months(3 * adjust);
|
||||||
|
}
|
||||||
|
since_specifier = date_specifier_t(adjust < 0 ? temp : base);
|
||||||
|
until_specifier = date_specifier_t(adjust < 0 ? base : temp);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case lexer_t::token_t::TOK_WEEK: {
|
case lexer_t::token_t::TOK_WEEK: {
|
||||||
date_t temp =
|
date_t base =
|
||||||
date_duration_t::find_nearest(today, date_duration_t::WEEKS);
|
date_duration_t::find_nearest(today, date_duration_t::WEEKS);
|
||||||
temp += gregorian::days(7 * adjust);
|
date_t temp;
|
||||||
inclusion_specifier = date_specifier_t(today);
|
if (adjust < 0) {
|
||||||
#if 0
|
temp = base + gregorian::days(7 * adjust);
|
||||||
period.duration = date_duration_t(date_duration_t::WEEKS, 1);
|
}
|
||||||
#endif
|
else if (adjust == 0) {
|
||||||
|
temp = base + gregorian::days(7);
|
||||||
|
}
|
||||||
|
else if (adjust > 0) {
|
||||||
|
base += gregorian::days(7 * adjust);
|
||||||
|
temp = base + gregorian::days(7 * adjust);
|
||||||
|
}
|
||||||
|
since_specifier = date_specifier_t(adjust < 0 ? temp : base);
|
||||||
|
until_specifier = date_specifier_t(adjust < 0 ? base : temp);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -862,6 +905,7 @@ date_interval_t date_parser_t::parse()
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
case lexer_t::token_t::TOK_TODAY:
|
case lexer_t::token_t::TOK_TODAY:
|
||||||
|
|
@ -876,7 +920,7 @@ date_interval_t date_parser_t::parse()
|
||||||
|
|
||||||
case lexer_t::token_t::TOK_EVERY:
|
case lexer_t::token_t::TOK_EVERY:
|
||||||
tok = lexer.next_token();
|
tok = lexer.next_token();
|
||||||
if (tok == lexer_t::token_t::TOK_INT) {
|
if (tok.kind == lexer_t::token_t::TOK_INT) {
|
||||||
int quantity = boost::get<unsigned short>(*tok.value);
|
int quantity = boost::get<unsigned short>(*tok.value);
|
||||||
tok = lexer.next_token();
|
tok = lexer.next_token();
|
||||||
switch (tok.kind) {
|
switch (tok.kind) {
|
||||||
|
|
@ -1052,8 +1096,8 @@ void date_interval_t::stabilize(const optional<date_t>& date)
|
||||||
// want a date early enough that the range will be correct, but late
|
// want a date early enough that the range will be correct, but late
|
||||||
// enough that we don't spend hundreds of thousands of loops skipping
|
// enough that we don't spend hundreds of thousands of loops skipping
|
||||||
// through time.
|
// through time.
|
||||||
optional<date_t> initial_start = start ? start : begin(date->year());
|
optional<date_t> initial_start = start ? start : begin();
|
||||||
optional<date_t> initial_finish = finish ? finish : end(date->year());
|
optional<date_t> initial_finish = finish ? finish : end();
|
||||||
|
|
||||||
#if defined(DEBUG_ON)
|
#if defined(DEBUG_ON)
|
||||||
if (initial_start)
|
if (initial_start)
|
||||||
|
|
@ -1116,13 +1160,8 @@ void date_interval_t::stabilize(const optional<date_t>& date)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
else if (range) {
|
else if (range) {
|
||||||
if (date) {
|
start = range->begin();
|
||||||
start = range->begin(date->year());
|
finish = range->end();
|
||||||
finish = range->end(date->year());
|
|
||||||
} else {
|
|
||||||
start = range->begin();
|
|
||||||
finish = range->end();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
aligned = true;
|
aligned = true;
|
||||||
}
|
}
|
||||||
|
|
@ -1228,7 +1267,7 @@ date_interval_t& date_interval_t::operator++()
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
void date_interval_t::dump(std::ostream& out, optional_year current_year)
|
void date_interval_t::dump(std::ostream& out)
|
||||||
{
|
{
|
||||||
out << _("--- Before stabilization ---") << std::endl;
|
out << _("--- Before stabilization ---") << std::endl;
|
||||||
|
|
||||||
|
|
@ -1242,7 +1281,7 @@ void date_interval_t::dump(std::ostream& out, optional_year current_year)
|
||||||
if (duration)
|
if (duration)
|
||||||
out << _("duration: ") << duration->to_string() << std::endl;
|
out << _("duration: ") << duration->to_string() << std::endl;
|
||||||
|
|
||||||
stabilize(begin(current_year));
|
stabilize(begin());
|
||||||
|
|
||||||
out << std::endl
|
out << std::endl
|
||||||
<< _("--- After stabilization ---") << std::endl;
|
<< _("--- After stabilization ---") << std::endl;
|
||||||
|
|
@ -1317,7 +1356,7 @@ date_parser_t::lexer_t::token_t date_parser_t::lexer_t::next_token()
|
||||||
|
|
||||||
try {
|
try {
|
||||||
date_traits_t traits;
|
date_traits_t traits;
|
||||||
date_t when = parse_date_mask(possible_date.c_str(), none, &traits);
|
date_t when = parse_date_mask(possible_date.c_str(), &traits);
|
||||||
if (! when.is_not_a_date()) {
|
if (! when.is_not_a_date()) {
|
||||||
begin = i;
|
begin = i;
|
||||||
return token_t(token_t::TOK_DATE,
|
return token_t(token_t::TOK_DATE,
|
||||||
|
|
|
||||||
68
src/times.h
68
src/times.h
|
|
@ -77,27 +77,23 @@ extern optional<datetime_t> epoch;
|
||||||
#define CURRENT_DATE() \
|
#define CURRENT_DATE() \
|
||||||
(epoch ? epoch->date() : boost::gregorian::day_clock::universal_day())
|
(epoch ? epoch->date() : boost::gregorian::day_clock::universal_day())
|
||||||
|
|
||||||
extern date_time::weekdays start_of_week;
|
extern date_time::weekdays start_of_week;
|
||||||
|
|
||||||
optional<date_time::weekdays>
|
optional<date_time::weekdays>
|
||||||
string_to_day_of_week(const std::string& str);
|
string_to_day_of_week(const std::string& str);
|
||||||
optional<date_time::months_of_year>
|
optional<date_time::months_of_year>
|
||||||
string_to_month_of_year(const std::string& str);
|
string_to_month_of_year(const std::string& str);
|
||||||
|
|
||||||
typedef optional<date_t::year_type> optional_year;
|
datetime_t parse_datetime(const char * str);
|
||||||
|
|
||||||
datetime_t parse_datetime(const char * str, optional_year current_year = none);
|
inline datetime_t parse_datetime(const std::string& str) {
|
||||||
|
return parse_datetime(str.c_str());
|
||||||
inline datetime_t parse_datetime(const std::string& str,
|
|
||||||
optional_year current_year = none) {
|
|
||||||
return parse_datetime(str.c_str(), current_year);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
date_t parse_date(const char * str, optional_year current_year = none);
|
date_t parse_date(const char * str);
|
||||||
|
|
||||||
inline date_t parse_date(const std::string& str,
|
inline date_t parse_date(const std::string& str) {
|
||||||
optional_year current_year = none) {
|
return parse_date(str.c_str());
|
||||||
return parse_date(str.c_str(), current_year);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
enum format_type_t {
|
enum format_type_t {
|
||||||
|
|
@ -329,12 +325,11 @@ public:
|
||||||
TRACE_DTOR(date_specifier_t);
|
TRACE_DTOR(date_specifier_t);
|
||||||
}
|
}
|
||||||
|
|
||||||
date_t begin(const optional_year& current_year = none) const;
|
date_t begin() const;
|
||||||
date_t end(const optional_year& current_year = none) const;
|
date_t end() const;
|
||||||
|
|
||||||
bool is_within(const date_t& date,
|
bool is_within(const date_t& date) const {
|
||||||
const optional_year& current_year = none) const {
|
return date >= begin() && date < end();
|
||||||
return date >= begin(current_year) && date < end(current_year);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
optional<date_duration_t> implied_duration() const {
|
optional<date_duration_t> implied_duration() const {
|
||||||
|
|
@ -404,27 +399,26 @@ public:
|
||||||
TRACE_DTOR(date_range_t);
|
TRACE_DTOR(date_range_t);
|
||||||
}
|
}
|
||||||
|
|
||||||
optional<date_t> begin(const optional_year& current_year = none) const {
|
optional<date_t> begin() const {
|
||||||
if (range_begin)
|
if (range_begin)
|
||||||
return range_begin->begin(current_year);
|
return range_begin->begin();
|
||||||
else
|
else
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
optional<date_t> end(const optional_year& current_year = none) const {
|
optional<date_t> end() const {
|
||||||
if (range_end) {
|
if (range_end) {
|
||||||
if (end_inclusive)
|
if (end_inclusive)
|
||||||
return range_end->end(current_year);
|
return range_end->end();
|
||||||
else
|
else
|
||||||
return range_end->begin(current_year);
|
return range_end->begin();
|
||||||
} else {
|
} else {
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool is_within(const date_t& date,
|
bool is_within(const date_t& date) const {
|
||||||
const optional_year& current_year = none) const {
|
optional<date_t> b = begin();
|
||||||
optional<date_t> b = begin(current_year);
|
optional<date_t> e = end();
|
||||||
optional<date_t> e = end(current_year);
|
|
||||||
bool after_begin = b ? date >= *b : true;
|
bool after_begin = b ? date >= *b : true;
|
||||||
bool before_end = e ? date < *e : true;
|
bool before_end = e ? date < *e : true;
|
||||||
return after_begin && before_end;
|
return after_begin && before_end;
|
||||||
|
|
@ -482,19 +476,19 @@ public:
|
||||||
TRACE_DTOR(date_specifier_or_range_t);
|
TRACE_DTOR(date_specifier_or_range_t);
|
||||||
}
|
}
|
||||||
|
|
||||||
optional<date_t> begin(const optional_year& current_year = none) const {
|
optional<date_t> begin() const {
|
||||||
if (specifier_or_range.type() == typeid(date_specifier_t))
|
if (specifier_or_range.type() == typeid(date_specifier_t))
|
||||||
return boost::get<date_specifier_t>(specifier_or_range).begin(current_year);
|
return boost::get<date_specifier_t>(specifier_or_range).begin();
|
||||||
else if (specifier_or_range.type() == typeid(date_range_t))
|
else if (specifier_or_range.type() == typeid(date_range_t))
|
||||||
return boost::get<date_range_t>(specifier_or_range).begin(current_year);
|
return boost::get<date_range_t>(specifier_or_range).begin();
|
||||||
else
|
else
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
optional<date_t> end(const optional_year& current_year = none) const {
|
optional<date_t> end() const {
|
||||||
if (specifier_or_range.type() == typeid(date_specifier_t))
|
if (specifier_or_range.type() == typeid(date_specifier_t))
|
||||||
return boost::get<date_specifier_t>(specifier_or_range).end(current_year);
|
return boost::get<date_specifier_t>(specifier_or_range).end();
|
||||||
else if (specifier_or_range.type() == typeid(date_range_t))
|
else if (specifier_or_range.type() == typeid(date_range_t))
|
||||||
return boost::get<date_range_t>(specifier_or_range).end(current_year);
|
return boost::get<date_range_t>(specifier_or_range).end();
|
||||||
else
|
else
|
||||||
return none;
|
return none;
|
||||||
}
|
}
|
||||||
|
|
@ -571,11 +565,11 @@ public:
|
||||||
return is_valid();
|
return is_valid();
|
||||||
}
|
}
|
||||||
|
|
||||||
optional<date_t> begin(const optional_year& current_year = none) const {
|
optional<date_t> begin() const {
|
||||||
return start ? start : (range ? range->begin(current_year) : none);
|
return start ? start : (range ? range->begin() : none);
|
||||||
}
|
}
|
||||||
optional<date_t> end(const optional_year& current_year = none) const {
|
optional<date_t> end() const {
|
||||||
return finish ? finish : (range ? range->end(current_year) : none);
|
return finish ? finish : (range ? range->end() : none);
|
||||||
}
|
}
|
||||||
|
|
||||||
void parse(const string& str);
|
void parse(const string& str);
|
||||||
|
|
@ -590,7 +584,7 @@ public:
|
||||||
/** Find the current or next period containing date. Returns true if the
|
/** Find the current or next period containing date. Returns true if the
|
||||||
date_interval_t object has been altered to reflect the interval
|
date_interval_t object has been altered to reflect the interval
|
||||||
containing date, or false if no such period can be found. */
|
containing date, or false if no such period can be found. */
|
||||||
bool find_period(const date_t& date);
|
bool find_period(const date_t& date = CURRENT_DATE());
|
||||||
|
|
||||||
optional<date_t> inclusive_end() const {
|
optional<date_t> inclusive_end() const {
|
||||||
if (end_of_duration)
|
if (end_of_duration)
|
||||||
|
|
@ -601,7 +595,7 @@ public:
|
||||||
|
|
||||||
date_interval_t& operator++();
|
date_interval_t& operator++();
|
||||||
|
|
||||||
void dump(std::ostream& out, optional_year current_year = none);
|
void dump(std::ostream& out);
|
||||||
|
|
||||||
#if defined(HAVE_BOOST_SERIALIZATION)
|
#if defined(HAVE_BOOST_SERIALIZATION)
|
||||||
private:
|
private:
|
||||||
|
|
|
||||||
23
src/xact.cc
23
src/xact.cc
|
|
@ -509,7 +509,7 @@ namespace {
|
||||||
|
|
||||||
foreach (post_t * p, post.xact->posts) {
|
foreach (post_t * p, post.xact->posts) {
|
||||||
bind_scope_t bound_scope(args, *p);
|
bind_scope_t bound_scope(args, *p);
|
||||||
if (expr->calc(bound_scope).to_boolean())
|
if (expr->calc(bound_scope, args.locus, args.depth).to_boolean())
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
|
|
@ -522,7 +522,7 @@ namespace {
|
||||||
|
|
||||||
foreach (post_t * p, post.xact->posts) {
|
foreach (post_t * p, post.xact->posts) {
|
||||||
bind_scope_t bound_scope(args, *p);
|
bind_scope_t bound_scope(args, *p);
|
||||||
if (! expr->calc(bound_scope).to_boolean())
|
if (! expr->calc(bound_scope, args.locus, args.depth).to_boolean())
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
|
|
@ -629,8 +629,7 @@ namespace {
|
||||||
|
|
||||||
} // unnamed namespace
|
} // unnamed namespace
|
||||||
|
|
||||||
void auto_xact_t::extend_xact(xact_base_t& xact,
|
void auto_xact_t::extend_xact(xact_base_t& xact)
|
||||||
optional<date_t::year_type> current_year)
|
|
||||||
{
|
{
|
||||||
posts_list initial_posts(xact.posts.begin(), xact.posts.end());
|
posts_list initial_posts(xact.posts.begin(), xact.posts.end());
|
||||||
|
|
||||||
|
|
@ -680,10 +679,8 @@ void auto_xact_t::extend_xact(xact_base_t& xact,
|
||||||
if (deferred_notes) {
|
if (deferred_notes) {
|
||||||
foreach (deferred_tag_data_t& data, *deferred_notes) {
|
foreach (deferred_tag_data_t& data, *deferred_notes) {
|
||||||
if (data.apply_to_post == NULL)
|
if (data.apply_to_post == NULL)
|
||||||
initial_post->parse_tags(data.tag_data.c_str(),
|
initial_post->parse_tags(data.tag_data.c_str(), bound_scope,
|
||||||
bound_scope,
|
data.overwrite_existing);
|
||||||
data.overwrite_existing,
|
|
||||||
current_year);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (check_exprs) {
|
if (check_exprs) {
|
||||||
|
|
@ -694,9 +691,9 @@ void auto_xact_t::extend_xact(xact_base_t& xact,
|
||||||
else if (! pair.first.calc(bound_scope).to_boolean()) {
|
else if (! pair.first.calc(bound_scope).to_boolean()) {
|
||||||
if (pair.second == auto_xact_t::EXPR_ASSERTION) {
|
if (pair.second == auto_xact_t::EXPR_ASSERTION) {
|
||||||
throw_(parse_error,
|
throw_(parse_error,
|
||||||
_("Transaction assertion failed: %1" << pair.first));
|
_("Transaction assertion failed: %1") << pair.first);
|
||||||
} else {
|
} else {
|
||||||
warning_(_("Transaction check failed: %1" << pair.first));
|
warning_(_("Transaction check failed: %1") << pair.first);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -778,10 +775,8 @@ void auto_xact_t::extend_xact(xact_base_t& xact,
|
||||||
if (deferred_notes) {
|
if (deferred_notes) {
|
||||||
foreach (deferred_tag_data_t& data, *deferred_notes) {
|
foreach (deferred_tag_data_t& data, *deferred_notes) {
|
||||||
if (data.apply_to_post == post)
|
if (data.apply_to_post == post)
|
||||||
new_post->parse_tags(data.tag_data.c_str(),
|
new_post->parse_tags(data.tag_data.c_str(), bound_scope,
|
||||||
bound_scope,
|
data.overwrite_existing);
|
||||||
data.overwrite_existing,
|
|
||||||
current_year);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -196,15 +196,13 @@ public:
|
||||||
|
|
||||||
virtual void parse_tags(const char * p,
|
virtual void parse_tags(const char * p,
|
||||||
scope_t&,
|
scope_t&,
|
||||||
bool overwrite_existing = true,
|
bool overwrite_existing = true) {
|
||||||
optional<date_t::year_type> = none) {
|
|
||||||
if (! deferred_notes)
|
if (! deferred_notes)
|
||||||
deferred_notes = deferred_notes_list();
|
deferred_notes = deferred_notes_list();
|
||||||
deferred_notes->push_back(deferred_tag_data_t(p, overwrite_existing));
|
deferred_notes->push_back(deferred_tag_data_t(p, overwrite_existing));
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void extend_xact(xact_base_t& xact,
|
virtual void extend_xact(xact_base_t& xact);
|
||||||
optional<date_t::year_type> current_year);
|
|
||||||
|
|
||||||
#if defined(HAVE_BOOST_SERIALIZATION)
|
#if defined(HAVE_BOOST_SERIALIZATION)
|
||||||
private:
|
private:
|
||||||
|
|
|
||||||
|
|
@ -23,6 +23,7 @@ class RegressFile:
|
||||||
|
|
||||||
def is_directive(self, line):
|
def is_directive(self, line):
|
||||||
return line == "<<<\n" or \
|
return line == "<<<\n" or \
|
||||||
|
line == ">>>\n" or \
|
||||||
line == ">>>1\n" or \
|
line == ">>>1\n" or \
|
||||||
line == ">>>2\n" or \
|
line == ">>>2\n" or \
|
||||||
line.startswith("===")
|
line.startswith("===")
|
||||||
|
|
@ -42,10 +43,10 @@ class RegressFile:
|
||||||
def read_test(self, last_test = None):
|
def read_test(self, last_test = None):
|
||||||
test = {
|
test = {
|
||||||
'command': None,
|
'command': None,
|
||||||
'input': None,
|
'input': "",
|
||||||
'output': None,
|
'output': "",
|
||||||
'error': None,
|
'error': "",
|
||||||
'exitcode': None
|
'exitcode': 0
|
||||||
}
|
}
|
||||||
if last_test:
|
if last_test:
|
||||||
test['input'] = last_test['input']
|
test['input'] = last_test['input']
|
||||||
|
|
@ -54,7 +55,7 @@ class RegressFile:
|
||||||
while line:
|
while line:
|
||||||
if line == "<<<\n":
|
if line == "<<<\n":
|
||||||
(test['input'], line) = self.read_section()
|
(test['input'], line) = self.read_section()
|
||||||
elif line == ">>>1\n":
|
elif line == ">>>\n" or line == ">>>1\n":
|
||||||
(test['output'], line) = self.read_section()
|
(test['output'], line) = self.read_section()
|
||||||
elif line == ">>>2\n":
|
elif line == ">>>2\n":
|
||||||
(test['error'], line) = self.read_section()
|
(test['error'], line) = self.read_section()
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --abbrev-len=4
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX Asse:Inve:Vang:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX Asse:Inve:Vangua:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
Inco:Divi:Vang:VMMXX $-0.35 $-0.35
|
Inco:Divi:Vangua:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --account='payee + ":" + commodity'
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX RD:VM:As:In:Va:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX RD:VM:As:In:Vang:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
07-Feb-02 RD VMMXX RD:$:In:Di:Va:VMMXX $-0.35 $-0.35
|
07-Feb-02 RD VMMXX RD:$:In:Di:Vangu:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --amount-width=18
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Investm:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Dividen:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ reg --amount=10
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 10 10
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 10 10
|
||||||
In:Di:Vanguard:VMMXX 10 20
|
In:Divid:Vanguar:VMMXX 10 20
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -8,8 +8,8 @@ reg --collapse-if-zero
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --columns=100
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:Investments:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX Asse:Investment:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Dividends:Vanguard:VMMXX $-0.35 $-0.35
|
Incom:Dividends:Vanguard:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --account=commodity
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX VM:As:In:Va:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX VM:As:Inve:Vangu:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
07-Feb-02 RD VMMXX $:In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
07-Feb-02 RD VMMXX $:In:Divi:Vangua:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --payee=commodity
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
07-Feb-02 $ In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
07-Feb-02 $ In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --date-format='%Y'
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
2007 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
2007 RD VMMXX As:Investm:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Dividen:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --date-width=20
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Investm:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Dividen:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -24,13 +24,13 @@ reg --empty
|
||||||
Assets:Cash $-10.00 0
|
Assets:Cash $-10.00 0
|
||||||
08-Jan-01 January Expenses:One:Books $10.00 $10.00
|
08-Jan-01 January Expenses:One:Books $10.00 $10.00
|
||||||
Expenses:One:Two:Books $10.00 $20.00
|
Expenses:One:Two:Books $10.00 $20.00
|
||||||
Ex:One:Two:Three:Books $10.00 $30.00
|
Expe:On:Tw:Three:Books $10.00 $30.00
|
||||||
Assets:Cash $-30.00 0
|
Assets:Cash $-30.00 0
|
||||||
08-Jan-01 January Assets:Cash 0 0
|
08-Jan-01 January Assets:Cash 0 0
|
||||||
Income:Books 0 0
|
Income:Books 0 0
|
||||||
08-Jan-01 January Assets:Cash $30.00 $30.00
|
08-Jan-01 January Assets:Cash $30.00 $30.00
|
||||||
Income:One:Books $-10.00 $20.00
|
Income:One:Books $-10.00 $20.00
|
||||||
Income:One:Two:Books $-10.00 $10.00
|
Income:One:Two:Books $-10.00 $10.00
|
||||||
In:One:Two:Three:Books $-10.00 0
|
Inc:On:Two:Three:Books $-10.00 0
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -244,42 +244,42 @@ reg --now=2009/03/21 --forecast-while='total < $3500' books
|
||||||
09-Nov-30 End of November Expenses:Books $110.00 $2880.00
|
09-Nov-30 End of November Expenses:Books $110.00 $2880.00
|
||||||
09-Dec-01 December Expenses:Books $120.00 $3000.00
|
09-Dec-01 December Expenses:Books $120.00 $3000.00
|
||||||
09-Dec-31 End of December Expenses:Books $120.00 $3120.00
|
09-Dec-31 End of December Expenses:Books $120.00 $3120.00
|
||||||
09-May-01 Forecast transaction Expenses:Books $10.00 $3130.00
|
09-Apr-01 Forecast transaction Expenses:Books $10.00 $3130.00
|
||||||
09-Jun-01 Forecast transaction Expenses:Books $10.00 $3140.00
|
09-May-01 Forecast transaction Expenses:Books $10.00 $3140.00
|
||||||
09-Jul-01 Forecast transaction Expenses:Books $10.00 $3150.00
|
09-Jun-01 Forecast transaction Expenses:Books $10.00 $3150.00
|
||||||
09-Aug-01 Forecast transaction Expenses:Books $10.00 $3160.00
|
09-Jul-01 Forecast transaction Expenses:Books $10.00 $3160.00
|
||||||
09-Sep-01 Forecast transaction Expenses:Books $10.00 $3170.00
|
09-Aug-01 Forecast transaction Expenses:Books $10.00 $3170.00
|
||||||
09-Oct-01 Forecast transaction Expenses:Books $10.00 $3180.00
|
09-Sep-01 Forecast transaction Expenses:Books $10.00 $3180.00
|
||||||
09-Nov-01 Forecast transaction Expenses:Books $10.00 $3190.00
|
09-Oct-01 Forecast transaction Expenses:Books $10.00 $3190.00
|
||||||
09-Dec-01 Forecast transaction Expenses:Books $10.00 $3200.00
|
09-Nov-01 Forecast transaction Expenses:Books $10.00 $3200.00
|
||||||
10-Jan-01 Forecast transaction Expenses:Books $10.00 $3210.00
|
09-Dec-01 Forecast transaction Expenses:Books $10.00 $3210.00
|
||||||
10-Feb-01 Forecast transaction Expenses:Books $10.00 $3220.00
|
10-Jan-01 Forecast transaction Expenses:Books $10.00 $3220.00
|
||||||
10-Mar-01 Forecast transaction Expenses:Books $10.00 $3230.00
|
10-Feb-01 Forecast transaction Expenses:Books $10.00 $3230.00
|
||||||
10-Apr-01 Forecast transaction Expenses:Books $10.00 $3240.00
|
10-Mar-01 Forecast transaction Expenses:Books $10.00 $3240.00
|
||||||
10-May-01 Forecast transaction Expenses:Books $10.00 $3250.00
|
10-Apr-01 Forecast transaction Expenses:Books $10.00 $3250.00
|
||||||
10-Jun-01 Forecast transaction Expenses:Books $10.00 $3260.00
|
10-May-01 Forecast transaction Expenses:Books $10.00 $3260.00
|
||||||
10-Jul-01 Forecast transaction Expenses:Books $10.00 $3270.00
|
10-Jun-01 Forecast transaction Expenses:Books $10.00 $3270.00
|
||||||
10-Aug-01 Forecast transaction Expenses:Books $10.00 $3280.00
|
10-Jul-01 Forecast transaction Expenses:Books $10.00 $3280.00
|
||||||
10-Sep-01 Forecast transaction Expenses:Books $10.00 $3290.00
|
10-Aug-01 Forecast transaction Expenses:Books $10.00 $3290.00
|
||||||
10-Oct-01 Forecast transaction Expenses:Books $10.00 $3300.00
|
10-Sep-01 Forecast transaction Expenses:Books $10.00 $3300.00
|
||||||
10-Nov-01 Forecast transaction Expenses:Books $10.00 $3310.00
|
10-Oct-01 Forecast transaction Expenses:Books $10.00 $3310.00
|
||||||
10-Dec-01 Forecast transaction Expenses:Books $10.00 $3320.00
|
10-Nov-01 Forecast transaction Expenses:Books $10.00 $3320.00
|
||||||
11-Jan-01 Forecast transaction Expenses:Books $10.00 $3330.00
|
10-Dec-01 Forecast transaction Expenses:Books $10.00 $3330.00
|
||||||
11-Feb-01 Forecast transaction Expenses:Books $10.00 $3340.00
|
11-Jan-01 Forecast transaction Expenses:Books $10.00 $3340.00
|
||||||
11-Mar-01 Forecast transaction Expenses:Books $10.00 $3350.00
|
11-Feb-01 Forecast transaction Expenses:Books $10.00 $3350.00
|
||||||
11-Apr-01 Forecast transaction Expenses:Books $10.00 $3360.00
|
11-Mar-01 Forecast transaction Expenses:Books $10.00 $3360.00
|
||||||
11-May-01 Forecast transaction Expenses:Books $10.00 $3370.00
|
11-Apr-01 Forecast transaction Expenses:Books $10.00 $3370.00
|
||||||
11-Jun-01 Forecast transaction Expenses:Books $10.00 $3380.00
|
11-May-01 Forecast transaction Expenses:Books $10.00 $3380.00
|
||||||
11-Jul-01 Forecast transaction Expenses:Books $10.00 $3390.00
|
11-Jun-01 Forecast transaction Expenses:Books $10.00 $3390.00
|
||||||
11-Aug-01 Forecast transaction Expenses:Books $10.00 $3400.00
|
11-Jul-01 Forecast transaction Expenses:Books $10.00 $3400.00
|
||||||
11-Sep-01 Forecast transaction Expenses:Books $10.00 $3410.00
|
11-Aug-01 Forecast transaction Expenses:Books $10.00 $3410.00
|
||||||
11-Oct-01 Forecast transaction Expenses:Books $10.00 $3420.00
|
11-Sep-01 Forecast transaction Expenses:Books $10.00 $3420.00
|
||||||
11-Nov-01 Forecast transaction Expenses:Books $10.00 $3430.00
|
11-Oct-01 Forecast transaction Expenses:Books $10.00 $3430.00
|
||||||
11-Dec-01 Forecast transaction Expenses:Books $10.00 $3440.00
|
11-Nov-01 Forecast transaction Expenses:Books $10.00 $3440.00
|
||||||
12-Jan-01 Forecast transaction Expenses:Books $10.00 $3450.00
|
11-Dec-01 Forecast transaction Expenses:Books $10.00 $3450.00
|
||||||
12-Feb-01 Forecast transaction Expenses:Books $10.00 $3460.00
|
12-Jan-01 Forecast transaction Expenses:Books $10.00 $3460.00
|
||||||
12-Mar-01 Forecast transaction Expenses:Books $10.00 $3470.00
|
12-Feb-01 Forecast transaction Expenses:Books $10.00 $3470.00
|
||||||
12-Apr-01 Forecast transaction Expenses:Books $10.00 $3480.00
|
12-Mar-01 Forecast transaction Expenses:Books $10.00 $3480.00
|
||||||
12-May-01 Forecast transaction Expenses:Books $10.00 $3490.00
|
12-Apr-01 Forecast transaction Expenses:Books $10.00 $3490.00
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -51,16 +51,16 @@ P 2010/04/01 00:00:00 S 16 P
|
||||||
>>>1
|
>>>1
|
||||||
09-Jan-15 Commodities revalued <Revalued> 100 P 100 P
|
09-Jan-15 Commodities revalued <Revalued> 100 P 100 P
|
||||||
09-Feb-01 Commodities revalued <Revalued> 200 P 300 P
|
09-Feb-01 Commodities revalued <Revalued> 200 P 300 P
|
||||||
09-Feb-01 Sample 2a As:Brokerage:Stocks 300 P 600 P
|
09-Feb-01 Sample 2a Asset:Brokerage:Stocks 300 P 600 P
|
||||||
09-Mar-01 Commodities revalued <Revalued> 800 P 1400 P
|
09-Mar-01 Commodities revalued <Revalued> 800 P 1400 P
|
||||||
09-Mar-01 Sample 3a As:Brokerage:Stocks 700 P 2100 P
|
09-Mar-01 Sample 3a Asset:Brokerage:Stocks 700 P 2100 P
|
||||||
09-Apr-01 Commodities revalued <Revalued> 2400 P 4500 P
|
09-Apr-01 Commodities revalued <Revalued> 2400 P 4500 P
|
||||||
09-Apr-01 Sample 4a As:Brokerage:Stocks -1500 P 3000 P
|
09-Apr-01 Sample 4a Asset:Brokerage:Stocks -1500 P 3000 P
|
||||||
10-Feb-01 Commodities revalued <Revalued> -2400 P 600 P
|
10-Feb-01 Commodities revalued <Revalued> -2400 P 600 P
|
||||||
10-Feb-01 Sample 2b As:Brokerage:Stocks 300 P 900 P
|
10-Feb-01 Sample 2b Asset:Brokerage:Stocks 300 P 900 P
|
||||||
10-Mar-01 Commodities revalued <Revalued> 1200 P 2100 P
|
10-Mar-01 Commodities revalued <Revalued> 1200 P 2100 P
|
||||||
10-Mar-01 Sample 3b As:Brokerage:Stocks 700 P 2800 P
|
10-Mar-01 Sample 3b Asset:Brokerage:Stocks 700 P 2800 P
|
||||||
10-Apr-01 Commodities revalued <Revalued> 3200 P 6000 P
|
10-Apr-01 Commodities revalued <Revalued> 3200 P 6000 P
|
||||||
10-Apr-01 Sample 4b As:Brokerage:Stocks -1500 P 4500 P
|
10-Apr-01 Sample 4b Asset:Brokerage:Stocks -1500 P 4500 P
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --input-date-format='%m%%%d%%%Y'
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --invert
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX -0.350 VMMXX -0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX -0.350 VMMXX -0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $0.35 $0.35
|
In:Divid:Vanguar:VMMXX $0.35 $0.35
|
||||||
-0.350 VMMXX
|
-0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -49,18 +49,18 @@ P 2010/03/01 00:00:00 S 8 P
|
||||||
|
|
||||||
P 2010/04/01 00:00:00 S 16 P
|
P 2010/04/01 00:00:00 S 16 P
|
||||||
>>>1
|
>>>1
|
||||||
09-Jan-01 Sample 1a As:Brokerage:Stocks 200 P 200 P
|
09-Jan-01 Sample 1a Asset:Brokerage:Stocks 200 P 200 P
|
||||||
09-Feb-01 Commodities revalued <Revalued> 200 P 400 P
|
09-Feb-01 Commodities revalued <Revalued> 200 P 400 P
|
||||||
09-Feb-01 Sample 2a As:Brokerage:Stocks 400 P 800 P
|
09-Feb-01 Sample 2a Asset:Brokerage:Stocks 400 P 800 P
|
||||||
09-Mar-01 Commodities revalued <Revalued> 800 P 1600 P
|
09-Mar-01 Commodities revalued <Revalued> 800 P 1600 P
|
||||||
09-Mar-01 Sample 3a As:Brokerage:Stocks 800 P 2400 P
|
09-Mar-01 Sample 3a Asset:Brokerage:Stocks 800 P 2400 P
|
||||||
09-Apr-01 Commodities revalued <Revalued> 2400 P 4800 P
|
09-Apr-01 Commodities revalued <Revalued> 2400 P 4800 P
|
||||||
09-Apr-01 Sample 4a As:Brokerage:Stocks -1600 P 3200 P
|
09-Apr-01 Sample 4a Asset:Brokerage:Stocks -1600 P 3200 P
|
||||||
10-Feb-01 Commodities revalued <Revalued> -2400 P 800 P
|
10-Feb-01 Commodities revalued <Revalued> -2400 P 800 P
|
||||||
10-Feb-01 Sample 2b As:Brokerage:Stocks 400 P 1200 P
|
10-Feb-01 Sample 2b Asset:Brokerage:Stocks 400 P 1200 P
|
||||||
10-Mar-01 Commodities revalued <Revalued> 1200 P 2400 P
|
10-Mar-01 Commodities revalued <Revalued> 1200 P 2400 P
|
||||||
10-Mar-01 Sample 3b As:Brokerage:Stocks 800 P 3200 P
|
10-Mar-01 Sample 3b Asset:Brokerage:Stocks 800 P 3200 P
|
||||||
10-Apr-01 Commodities revalued <Revalued> 3200 P 6400 P
|
10-Apr-01 Commodities revalued <Revalued> 3200 P 6400 P
|
||||||
10-Apr-01 Sample 4b As:Brokerage:Stocks -1600 P 4800 P
|
10-Apr-01 Sample 4b Asset:Brokerage:Stocks -1600 P 4800 P
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ reg --output=/dev/stderr
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
>>>2
|
>>>2
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --pager=cat
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -22,12 +22,12 @@ reg --account=payee
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-01 January January:Expenses:Books $10.00 $10.00
|
08-Jan-01 January January:Expenses:Books $10.00 $10.00
|
||||||
08-Jan-01 January January:Assets:Cash $-10.00 0
|
08-Jan-01 January January:Assets:Cash $-10.00 0
|
||||||
08-Jan-31 End of January En:Expenses:Books $10.00 $10.00
|
08-Jan-31 End of January End of J:Expense:Books $10.00 $10.00
|
||||||
08-Jan-31 End of January En:Assets:Cash $-10.00 0
|
08-Jan-31 End of January End of Jan:Assets:Cash $-10.00 0
|
||||||
08-Feb-01 February Fe:Expenses:Books $20.00 $20.00
|
08-Feb-01 February Februar:Expenses:Books $20.00 $20.00
|
||||||
08-Feb-01 February February:Assets:Cash $-20.00 0
|
08-Feb-01 February February:Assets:Cash $-20.00 0
|
||||||
08-Feb-28 End of February En:Expenses:Books $20.00 $20.00
|
08-Feb-28 End of February End of F:Expense:Books $20.00 $20.00
|
||||||
08-Feb-28 End of February En:Assets:Cash $-20.00 0
|
08-Feb-28 End of February End of Feb:Assets:Cash $-20.00 0
|
||||||
08-Mar-01 March March:Expenses:Books $30.00 $30.00
|
08-Mar-01 March March:Expenses:Books $30.00 $30.00
|
||||||
08-Mar-01 March March:Assets:Cash $-30.00 0
|
08-Mar-01 March March:Assets:Cash $-30.00 0
|
||||||
>>>2
|
>>>2
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --payee-width=40
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Investm:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Dividen:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --payee='account_base + ":" + commodity'
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 VMMXX:VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 VMMXX:VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
07-Feb-02 VMMXX:$ In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
07-Feb-02 VMMXX:$ In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --quantity
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Divid:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -49,18 +49,18 @@ P 2010/03/01 00:00:00 S 8 P
|
||||||
|
|
||||||
P 2010/04/01 00:00:00 S 16 P
|
P 2010/04/01 00:00:00 S 16 P
|
||||||
>>>1
|
>>>1
|
||||||
09-Jan-01 Sample 1a As:Brokerage:Stocks 200 P 200 P
|
09-Jan-01 Sample 1a Asset:Brokerage:Stocks 200 P 200 P
|
||||||
09-Feb-01 Commodities revalued <Revalued> 200 P 400 P
|
09-Feb-01 Commodities revalued <Revalued> 200 P 400 P
|
||||||
09-Feb-01 Sample 2a As:Brokerage:Stocks 400 P 800 P
|
09-Feb-01 Sample 2a Asset:Brokerage:Stocks 400 P 800 P
|
||||||
09-Mar-01 Commodities revalued <Revalued> 800 P 1600 P
|
09-Mar-01 Commodities revalued <Revalued> 800 P 1600 P
|
||||||
09-Mar-01 Sample 3a As:Brokerage:Stocks 800 P 2400 P
|
09-Mar-01 Sample 3a Asset:Brokerage:Stocks 800 P 2400 P
|
||||||
09-Apr-01 Commodities revalued <Revalued> 2400 P 4800 P
|
09-Apr-01 Commodities revalued <Revalued> 2400 P 4800 P
|
||||||
09-Apr-01 Sample 4a As:Brokerage:Stocks -1600 P 3200 P
|
09-Apr-01 Sample 4a Asset:Brokerage:Stocks -1600 P 3200 P
|
||||||
10-Feb-01 Commodities revalued <Revalued> -2400 P 800 P
|
10-Feb-01 Commodities revalued <Revalued> -2400 P 800 P
|
||||||
10-Feb-01 Sample 2b As:Brokerage:Stocks 400 P 1200 P
|
10-Feb-01 Sample 2b Asset:Brokerage:Stocks 400 P 1200 P
|
||||||
10-Mar-01 Commodities revalued <Revalued> 1200 P 2400 P
|
10-Mar-01 Commodities revalued <Revalued> 1200 P 2400 P
|
||||||
10-Mar-01 Sample 3b As:Brokerage:Stocks 800 P 3200 P
|
10-Mar-01 Sample 3b Asset:Brokerage:Stocks 800 P 3200 P
|
||||||
10-Apr-01 Commodities revalued <Revalued> 3200 P 6400 P
|
10-Apr-01 Commodities revalued <Revalued> 3200 P 6400 P
|
||||||
10-Apr-01 Sample 4b As:Brokerage:Stocks -1600 P 4800 P
|
10-Apr-01 Sample 4b Asset:Brokerage:Stocks -1600 P 4800 P
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -84,33 +84,33 @@ reg --monthly --sort=-amount
|
||||||
Expenses:Travel:Passport $127.00
|
Expenses:Travel:Passport $127.00
|
||||||
Assets:Checking
|
Assets:Checking
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-01 - 08-Jan-31 Ex:Travel:Airfare $222.19 $222.19
|
08-Jan-01 - 08-Jan-31 Expense:Travel:Airfare $222.19 $222.19
|
||||||
Liabilities:MasterCard $-222.19 0
|
Liabilities:MasterCard $-222.19 0
|
||||||
08-Feb-01 - 08-Feb-29 Ex:Travel:Airfare $477.60 $477.60
|
08-Feb-01 - 08-Feb-29 Expense:Travel:Airfare $477.60 $477.60
|
||||||
Expenses:Travel:Auto $280.97 $758.57
|
Expenses:Travel:Auto $280.97 $758.57
|
||||||
Liabilities:MasterCard $-758.57 0
|
Liabilities:MasterCard $-758.57 0
|
||||||
08-Mar-01 - 08-Mar-31 Ex:Travel:Airfare $2,463.20 $2,463.20
|
08-Mar-01 - 08-Mar-31 Expense:Travel:Airfare $2,463.20 $2,463.20
|
||||||
Liabilities:MasterCard $-2,463.20 0
|
Liabilities:MasterCard $-2,463.20 0
|
||||||
08-Apr-01 - 08-Apr-30 Ex:Travel:Airfare $1,186.14 $1,186.14
|
08-Apr-01 - 08-Apr-30 Expense:Travel:Airfare $1,186.14 $1,186.14
|
||||||
Liabilities:MasterCard $-1,186.14 0
|
Liabilities:MasterCard $-1,186.14 0
|
||||||
08-Aug-01 - 08-Aug-31 Ex:Travel:Passport $170.00 $170.00
|
08-Aug-01 - 08-Aug-31 Expens:Travel:Passport $170.00 $170.00
|
||||||
Liabilities:MasterCard $-170.00 0
|
Liabilities:MasterCard $-170.00 0
|
||||||
08-Sep-01 - 08-Sep-30 Ex:Travel:Airfare $3,925.94 $3,925.94
|
08-Sep-01 - 08-Sep-30 Expense:Travel:Airfare $3,925.94 $3,925.94
|
||||||
Liabilities:MasterCard $-3,925.94 0
|
Liabilities:MasterCard $-3,925.94 0
|
||||||
08-Dec-01 - 08-Dec-31 Ex:Travel:Passport $254.00 $254.00
|
08-Dec-01 - 08-Dec-31 Expens:Travel:Passport $254.00 $254.00
|
||||||
Assets:Checking $-254.00 0
|
Assets:Checking $-254.00 0
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
reg --monthly --sort-all=-amount
|
reg --monthly --sort-all=-amount
|
||||||
>>>1
|
>>>1
|
||||||
08-Sep-01 - 08-Sep-30 Ex:Travel:Airfare $3,925.94 $3,925.94
|
08-Sep-01 - 08-Sep-30 Expense:Travel:Airfare $3,925.94 $3,925.94
|
||||||
08-Mar-01 - 08-Mar-31 Ex:Travel:Airfare $2,463.20 $6,389.14
|
08-Mar-01 - 08-Mar-31 Expense:Travel:Airfare $2,463.20 $6,389.14
|
||||||
08-Apr-01 - 08-Apr-30 Ex:Travel:Airfare $1,186.14 $7,575.28
|
08-Apr-01 - 08-Apr-30 Expense:Travel:Airfare $1,186.14 $7,575.28
|
||||||
08-Feb-01 - 08-Feb-29 Ex:Travel:Airfare $477.60 $8,052.88
|
08-Feb-01 - 08-Feb-29 Expense:Travel:Airfare $477.60 $8,052.88
|
||||||
Expenses:Travel:Auto $280.97 $8,333.85
|
Expenses:Travel:Auto $280.97 $8,333.85
|
||||||
08-Dec-01 - 08-Dec-31 Ex:Travel:Passport $254.00 $8,587.85
|
08-Dec-01 - 08-Dec-31 Expens:Travel:Passport $254.00 $8,587.85
|
||||||
08-Jan-01 - 08-Jan-31 Ex:Travel:Airfare $222.19 $8,810.04
|
08-Jan-01 - 08-Jan-31 Expense:Travel:Airfare $222.19 $8,810.04
|
||||||
08-Aug-01 - 08-Aug-31 Ex:Travel:Passport $170.00 $8,980.04
|
08-Aug-01 - 08-Aug-31 Expens:Travel:Passport $170.00 $8,980.04
|
||||||
Liabilities:MasterCard $-170.00 $8,810.04
|
Liabilities:MasterCard $-170.00 $8,810.04
|
||||||
08-Jan-01 - 08-Jan-31 Liabilities:MasterCard $-222.19 $8,587.85
|
08-Jan-01 - 08-Jan-31 Liabilities:MasterCard $-222.19 $8,587.85
|
||||||
08-Dec-01 - 08-Dec-31 Assets:Checking $-254.00 $8,333.85
|
08-Dec-01 - 08-Dec-31 Assets:Checking $-254.00 $8,333.85
|
||||||
|
|
|
||||||
|
|
@ -86,27 +86,27 @@ reg --sort=account
|
||||||
>>>1
|
>>>1
|
||||||
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
||||||
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-254.00
|
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-254.00
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $-214.00
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $-214.00
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $-31.81
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $-31.81
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $206.99
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $206.99
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $445.79
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $445.79
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,677.39
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,677.39
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $2,908.99
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $2,908.99
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,064.85
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,064.85
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,220.71
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,220.71
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $3,657.92
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $3,657.92
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,095.13
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,095.13
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,007.73
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,007.73
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,920.33
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,920.33
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $5,990.33
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $5,990.33
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $6,796.53
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $6,796.53
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $7,602.73
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $7,602.73
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $8,021.07
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $8,021.07
|
||||||
08-Feb-05 CTX Expenses:Travel:Auto $240.38 $8,261.45
|
08-Feb-05 CTX Expenses:Travel:Auto $240.38 $8,261.45
|
||||||
08-Feb-22 BUDGET RENT-A-CAR Expenses:Travel:Auto $40.59 $8,302.04
|
08-Feb-22 BUDGET RENT-A-CAR Expenses:Travel:Auto $40.59 $8,302.04
|
||||||
08-Aug-08 BCIS I-131 FILING F.. Ex:Travel:Passport $170.00 $8,472.04
|
08-Aug-08 BCIS I-131 FILING F.. Expens:Travel:Passport $170.00 $8,472.04
|
||||||
08-Dec-26 U.S. Department of .. Ex:Travel:Passport $127.00 $8,599.04
|
08-Dec-26 U.S. Department of .. Expens:Travel:Passport $127.00 $8,599.04
|
||||||
08-Dec-26 U.S. Department of .. Ex:Travel:Passport $127.00 $8,726.04
|
08-Dec-26 U.S. Department of .. Expens:Travel:Passport $127.00 $8,726.04
|
||||||
08-Jan-11 LIAT Liabilities:MasterCard $-40.00 $8,686.04
|
08-Jan-11 LIAT Liabilities:MasterCard $-40.00 $8,686.04
|
||||||
08-Jan-14 cheaptickets.com Liabilities:MasterCard $-182.19 $8,503.85
|
08-Jan-14 cheaptickets.com Liabilities:MasterCard $-182.19 $8,503.85
|
||||||
08-Feb-05 CTX Liabilities:MasterCard $-240.38 $8,263.47
|
08-Feb-05 CTX Liabilities:MasterCard $-240.38 $8,263.47
|
||||||
|
|
@ -130,47 +130,47 @@ reg --sort=account
|
||||||
=== 0
|
=== 0
|
||||||
reg --sort-xacts=account
|
reg --sort-xacts=account
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $40.00
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $40.00
|
||||||
Liabilities:MasterCard $-40.00 0
|
Liabilities:MasterCard $-40.00 0
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $182.19
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $182.19
|
||||||
Liabilities:MasterCard $-182.19 0
|
Liabilities:MasterCard $-182.19 0
|
||||||
08-Feb-05 CTX Expenses:Travel:Auto $240.38 $240.38
|
08-Feb-05 CTX Expenses:Travel:Auto $240.38 $240.38
|
||||||
Liabilities:MasterCard $-240.38 0
|
Liabilities:MasterCard $-240.38 0
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $238.80
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $238.80
|
||||||
Liabilities:MasterCard $-238.80 0
|
Liabilities:MasterCard $-238.80 0
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $238.80
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $238.80
|
||||||
Liabilities:MasterCard $-238.80 0
|
Liabilities:MasterCard $-238.80 0
|
||||||
08-Feb-22 BUDGET RENT-A-CAR Expenses:Travel:Auto $40.59 $40.59
|
08-Feb-22 BUDGET RENT-A-CAR Expenses:Travel:Auto $40.59 $40.59
|
||||||
Liabilities:MasterCard $-40.59 0
|
Liabilities:MasterCard $-40.59 0
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,231.60
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,231.60
|
||||||
Liabilities:MasterCard $-1,231.60 0
|
Liabilities:MasterCard $-1,231.60 0
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,231.60
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,231.60
|
||||||
Liabilities:MasterCard $-1,231.60 0
|
Liabilities:MasterCard $-1,231.60 0
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $155.86
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $155.86
|
||||||
Liabilities:MasterCard $-155.86 0
|
Liabilities:MasterCard $-155.86 0
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $155.86
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $155.86
|
||||||
Liabilities:MasterCard $-155.86 0
|
Liabilities:MasterCard $-155.86 0
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $437.21
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $437.21
|
||||||
Liabilities:MasterCard $-437.21 0
|
Liabilities:MasterCard $-437.21 0
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $437.21
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $437.21
|
||||||
Liabilities:MasterCard $-437.21 0
|
Liabilities:MasterCard $-437.21 0
|
||||||
08-Aug-08 BCIS I-131 FILING F.. Ex:Travel:Passport $170.00 $170.00
|
08-Aug-08 BCIS I-131 FILING F.. Expens:Travel:Passport $170.00 $170.00
|
||||||
Liabilities:MasterCard $-170.00 0
|
Liabilities:MasterCard $-170.00 0
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $912.60
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $912.60
|
||||||
Liabilities:MasterCard $-912.60 0
|
Liabilities:MasterCard $-912.60 0
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $912.60
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $912.60
|
||||||
Liabilities:MasterCard $-912.60 0
|
Liabilities:MasterCard $-912.60 0
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $70.00
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $70.00
|
||||||
Liabilities:MasterCard $-70.00 0
|
Liabilities:MasterCard $-70.00 0
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $806.20
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $806.20
|
||||||
Liabilities:MasterCard $-806.20 0
|
Liabilities:MasterCard $-806.20 0
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $806.20
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $806.20
|
||||||
Liabilities:MasterCard $-806.20 0
|
Liabilities:MasterCard $-806.20 0
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $418.34
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $418.34
|
||||||
Liabilities:MasterCard $-418.34 0
|
Liabilities:MasterCard $-418.34 0
|
||||||
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
||||||
Ex:Travel:Passport $127.00 0
|
Expens:Travel:Passport $127.00 0
|
||||||
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
||||||
Ex:Travel:Passport $127.00 0
|
Expens:Travel:Passport $127.00 0
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -84,82 +84,82 @@ reg airfare --sort=date
|
||||||
Expenses:Travel:Passport $127.00
|
Expenses:Travel:Passport $127.00
|
||||||
Assets:Checking
|
Assets:Checking
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $40.00
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $40.00
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $222.19
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $222.19
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $460.99
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $460.99
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $699.79
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $699.79
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,931.39
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,931.39
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $3,162.99
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $3,162.99
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,318.85
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,318.85
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,474.71
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,474.71
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $3,911.92
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $3,911.92
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,349.13
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,349.13
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,261.73
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,261.73
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $6,174.33
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $6,174.33
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $6,244.33
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $6,244.33
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $7,050.53
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $7,050.53
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $7,856.73
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $7,856.73
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $8,275.07
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $8,275.07
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
reg airfare --sort=date,amount
|
reg airfare --sort=date,amount
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $40.00
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $40.00
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $222.19
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $222.19
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $460.99
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $460.99
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $699.79
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $699.79
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,931.39
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,931.39
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $3,162.99
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $3,162.99
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,318.85
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,318.85
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,474.71
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,474.71
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $3,911.92
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $3,911.92
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,349.13
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,349.13
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,261.73
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,261.73
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $6,174.33
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $6,174.33
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $6,244.33
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $6,244.33
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $6,662.67
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $6,662.67
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $7,468.87
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $7,468.87
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $8,275.07
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $8,275.07
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
reg airfare --sort=date,-amount
|
reg airfare --sort=date,-amount
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $40.00
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $40.00
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $222.19
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $222.19
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $460.99
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $460.99
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $699.79
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $699.79
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,931.39
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,931.39
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $3,162.99
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $3,162.99
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,318.85
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,318.85
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,474.71
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,474.71
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $3,911.92
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $3,911.92
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,349.13
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,349.13
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,261.73
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,261.73
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $6,174.33
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $6,174.33
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $6,980.53
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $6,980.53
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $7,786.73
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $7,786.73
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $8,205.07
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $8,205.07
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $8,275.07
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $8,275.07
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
reg airfare --sort=-date,-amount
|
reg airfare --sort=-date,-amount
|
||||||
>>>1
|
>>>1
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $806.20
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $806.20
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $1,612.40
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $1,612.40
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $2,030.74
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $2,030.74
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $2,100.74
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $2,100.74
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $3,013.34
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $3,013.34
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $3,925.94
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $3,925.94
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,363.15
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,363.15
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,800.36
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,800.36
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $4,956.22
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $4,956.22
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $5,112.08
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $5,112.08
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $6,343.68
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $6,343.68
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $7,575.28
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $7,575.28
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $7,814.08
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $7,814.08
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $8,052.88
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $8,052.88
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $8,235.07
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $8,235.07
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $8,275.07
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $8,275.07
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
bal --sort=total
|
bal --sort=total
|
||||||
|
|
@ -202,27 +202,27 @@ reg --sort=account
|
||||||
>>>1
|
>>>1
|
||||||
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-127.00
|
||||||
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-254.00
|
08-Dec-26 U.S. Department of .. Assets:Checking $-127.00 $-254.00
|
||||||
08-Jan-11 LIAT Ex:Travel:Airfare $40.00 $-214.00
|
08-Jan-11 LIAT Expense:Travel:Airfare $40.00 $-214.00
|
||||||
08-Jan-14 cheaptickets.com Ex:Travel:Airfare $182.19 $-31.81
|
08-Jan-14 cheaptickets.com Expense:Travel:Airfare $182.19 $-31.81
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $206.99
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $206.99
|
||||||
08-Feb-05 UNITED Ex:Travel:Airfare $238.80 $445.79
|
08-Feb-05 UNITED Expense:Travel:Airfare $238.80 $445.79
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $1,677.39
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $1,677.39
|
||||||
08-Mar-16 IBERIA Ex:Travel:Airfare $1,231.60 $2,908.99
|
08-Mar-16 IBERIA Expense:Travel:Airfare $1,231.60 $2,908.99
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,064.85
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,064.85
|
||||||
08-Apr-03 AMERICAN Ex:Travel:Airfare $155.86 $3,220.71
|
08-Apr-03 AMERICAN Expense:Travel:Airfare $155.86 $3,220.71
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $3,657.92
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $3,657.92
|
||||||
08-Apr-30 UNITED Ex:Travel:Airfare $437.21 $4,095.13
|
08-Apr-30 UNITED Expense:Travel:Airfare $437.21 $4,095.13
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,007.73
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,007.73
|
||||||
08-Sep-06 AMERICAN Ex:Travel:Airfare $912.60 $5,920.33
|
08-Sep-06 AMERICAN Expense:Travel:Airfare $912.60 $5,920.33
|
||||||
08-Sep-22 AGNT FEE Ex:Travel:Airfare $70.00 $5,990.33
|
08-Sep-22 AGNT FEE Expense:Travel:Airfare $70.00 $5,990.33
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $6,796.53
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $6,796.53
|
||||||
08-Sep-22 DELTA Ex:Travel:Airfare $806.20 $7,602.73
|
08-Sep-22 DELTA Expense:Travel:Airfare $806.20 $7,602.73
|
||||||
08-Sep-22 LIAT 1974 LIMITED Ex:Travel:Airfare $418.34 $8,021.07
|
08-Sep-22 LIAT 1974 LIMITED Expense:Travel:Airfare $418.34 $8,021.07
|
||||||
08-Feb-05 CTX Expenses:Travel:Auto $240.38 $8,261.45
|
08-Feb-05 CTX Expenses:Travel:Auto $240.38 $8,261.45
|
||||||
08-Feb-22 BUDGET RENT-A-CAR Expenses:Travel:Auto $40.59 $8,302.04
|
08-Feb-22 BUDGET RENT-A-CAR Expenses:Travel:Auto $40.59 $8,302.04
|
||||||
08-Aug-08 BCIS I-131 FILING F.. Ex:Travel:Passport $170.00 $8,472.04
|
08-Aug-08 BCIS I-131 FILING F.. Expens:Travel:Passport $170.00 $8,472.04
|
||||||
08-Dec-26 U.S. Department of .. Ex:Travel:Passport $127.00 $8,599.04
|
08-Dec-26 U.S. Department of .. Expens:Travel:Passport $127.00 $8,599.04
|
||||||
08-Dec-26 U.S. Department of .. Ex:Travel:Passport $127.00 $8,726.04
|
08-Dec-26 U.S. Department of .. Expens:Travel:Passport $127.00 $8,726.04
|
||||||
08-Jan-11 LIAT Liabilities:MasterCard $-40.00 $8,686.04
|
08-Jan-11 LIAT Liabilities:MasterCard $-40.00 $8,686.04
|
||||||
08-Jan-14 cheaptickets.com Liabilities:MasterCard $-182.19 $8,503.85
|
08-Jan-14 cheaptickets.com Liabilities:MasterCard $-182.19 $8,503.85
|
||||||
08-Feb-05 CTX Liabilities:MasterCard $-240.38 $8,263.47
|
08-Feb-05 CTX Liabilities:MasterCard $-240.38 $8,263.47
|
||||||
|
|
|
||||||
|
|
@ -85,9 +85,9 @@ reg --subtotal
|
||||||
Assets:Checking
|
Assets:Checking
|
||||||
>>>1
|
>>>1
|
||||||
08-Jan-11 - 08-Dec-26 Assets:Checking $-254.00 $-254.00
|
08-Jan-11 - 08-Dec-26 Assets:Checking $-254.00 $-254.00
|
||||||
Ex:Travel:Airfare $8,275.07 $8,021.07
|
Expense:Travel:Airfare $8,275.07 $8,021.07
|
||||||
Expenses:Travel:Auto $280.97 $8,302.04
|
Expenses:Travel:Auto $280.97 $8,302.04
|
||||||
Ex:Travel:Passport $424.00 $8,726.04
|
Expens:Travel:Passport $424.00 $8,726.04
|
||||||
Liabilities:MasterCard $-8,726.04 0
|
Liabilities:MasterCard $-8,726.04 0
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,8 +4,8 @@ reg --total-width=25
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 0.350 VMMXX
|
07-Feb-02 RD VMMXX As:Investm:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
|
||||||
In:Di:Vanguard:VMMXX $-0.35 $-0.35
|
In:Dividen:Vanguar:VMMXX $-0.35 $-0.35
|
||||||
0.350 VMMXX
|
0.350 VMMXX
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ reg --total=10
|
||||||
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
|
||||||
Income:Dividends:Vanguard:VMMXX $-0.35
|
Income:Dividends:Vanguard:VMMXX $-0.35
|
||||||
>>>1
|
>>>1
|
||||||
07-Feb-02 RD VMMXX As:In:Vanguard:VMMXX 0.350 VMMXX 10
|
07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 10
|
||||||
In:Di:Vanguard:VMMXX $-0.35 10
|
In:Divid:Vanguar:VMMXX $-0.35 10
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -8,10 +8,10 @@ reg
|
||||||
Expenses:School:CS Club:Home Depot:4" Brush (2 * $3.97)
|
Expenses:School:CS Club:Home Depot:4" Brush (2 * $3.97)
|
||||||
Liabilities:Mastercard
|
Liabilities:Mastercard
|
||||||
>>>1
|
>>>1
|
||||||
09-Apr-04 CS Club Sign Ex:Sc:CS:Ho:4" Brush 2 2
|
09-Apr-04 CS Club Sign Ex:Sc:CS:Home:4" Brush 2 2
|
||||||
Liabilities:Mastercard $-7.94 2
|
Liabilities:Mastercard $-7.94 2
|
||||||
$-7.94
|
$-7.94
|
||||||
09-Apr-04 CS Club Sign Ex:Sc:CS:Ho:4" Brush $7.94 2
|
09-Apr-04 CS Club Sign Ex:Sc:CS:Home:4" Brush $7.94 2
|
||||||
Liabilities:Mastercard $-7.94 2
|
Liabilities:Mastercard $-7.94 2
|
||||||
$-7.94
|
$-7.94
|
||||||
>>>2
|
>>>2
|
||||||
|
|
|
||||||
|
|
@ -46,9 +46,9 @@ N $
|
||||||
; :AnotherTag:
|
; :AnotherTag:
|
||||||
>>>1
|
>>>1
|
||||||
04-May-01 Checking balance [34mAssets:Bank:Checking [0m $1,000.00 $1,000.00
|
04-May-01 Checking balance [34mAssets:Bank:Checking [0m $1,000.00 $1,000.00
|
||||||
[34mEq:Opening Balances [0m [31m$-1,000.00[0m 0
|
[34mEquit:Opening Balances[0m [31m$-1,000.00[0m 0
|
||||||
04-May-03 Investment balance [34mAssets:Brokerage [0m 50 AAPL 50 AAPL
|
04-May-03 Investment balance [34mAssets:Brokerage [0m 50 AAPL 50 AAPL
|
||||||
[34mEq:Opening Balances [0m [31m$-1,500.00[0m [31m$-1,500.00[0m
|
[34mEquit:Opening Balances[0m [31m$-1,500.00[0m [31m$-1,500.00[0m
|
||||||
50 AAPL
|
50 AAPL
|
||||||
04-May-14 Páy dày [34mAssets:Bank:Checking [0m 500.00€ [31m$-1,500.00[0m
|
04-May-14 Páy dày [34mAssets:Bank:Checking [0m 500.00€ [31m$-1,500.00[0m
|
||||||
50 AAPL
|
50 AAPL
|
||||||
|
|
@ -59,7 +59,7 @@ N $
|
||||||
50 AAPL
|
50 AAPL
|
||||||
[34mIncome:Salary [0m [31m$-500.00[0m [31m$-1,500.00[0m
|
[34mIncome:Salary [0m [31m$-500.00[0m [31m$-1,500.00[0m
|
||||||
50 AAPL
|
50 AAPL
|
||||||
04-May-14 Another dày in whic.. [34mРу:Ру:Ру:Русский язык [0m $1,000.00 [31m$-500.00[0m
|
04-May-14 Another dày in whic.. [34mРу:Ру:Рус:Русский язык[0m $1,000.00 [31m$-500.00[0m
|
||||||
50 AAPL
|
50 AAPL
|
||||||
[34mIncome:Salary [0m [31m$-1,000.00[0m [31m$-1,500.00[0m
|
[34mIncome:Salary [0m [31m$-1,000.00[0m [31m$-1,500.00[0m
|
||||||
50 AAPL
|
50 AAPL
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ reg -B
|
||||||
Expenses:Bank:Fees 2.73
|
Expenses:Bank:Fees 2.73
|
||||||
Liabilities:Mastercard
|
Liabilities:Mastercard
|
||||||
>>>1
|
>>>1
|
||||||
09-Jun-03 Westjet Ex:Transportation:Air 676.017377 676.017377
|
09-Jun-03 Westjet Expen:Transportati:Air 676.017377 676.017377
|
||||||
Expenses:Bank:Fees 2.73 678.747377
|
Expenses:Bank:Fees 2.73 678.747377
|
||||||
Liabilities:Mastercard -678.747377 0
|
Liabilities:Mastercard -678.747377 0
|
||||||
>>>2
|
>>>2
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ D 1000.00 EUR
|
||||||
|
|
||||||
P 2008/04/20 00:00:00 CAD 1.20 EUR
|
P 2008/04/20 00:00:00 CAD 1.20 EUR
|
||||||
>>>1
|
>>>1
|
||||||
08-Apr-15 Paid expenses back .. Ex:Cie-Reimbursements 2200.00 EUR 2200.00 EUR
|
08-Apr-15 Paid expenses back .. Exp:Cie-Reimbursements 2200.00 EUR 2200.00 EUR
|
||||||
Assets:Checking -2200.00 EUR 0
|
Assets:Checking -2200.00 EUR 0
|
||||||
08-Apr-20 Commodities revalued <Revalued> 200.00 EUR 200.00 EUR
|
08-Apr-20 Commodities revalued <Revalued> 200.00 EUR 200.00 EUR
|
||||||
>>>2
|
>>>2
|
||||||
|
|
|
||||||
|
|
@ -10,15 +10,15 @@ reg
|
||||||
Assets:Investments:RBC-Broker:Account-RSP 72.06 CAD
|
Assets:Investments:RBC-Broker:Account-RSP 72.06 CAD
|
||||||
Expenses:Financial:Fees
|
Expenses:Financial:Fees
|
||||||
>>>1
|
>>>1
|
||||||
07-Dec-31 Cost basis for: RED.. As:In:RB:Account-RSP 4.00 RHT 4.00 RHT
|
07-Dec-31 Cost basis for: RED.. As:In:RBC-:Account-RSP 4.00 RHT 4.00 RHT
|
||||||
Eq:Op:Cost -689.87 CAD -689.87 CAD
|
Equ:Opening-Balan:Cost -689.87 CAD -689.87 CAD
|
||||||
4.00 RHT
|
4.00 RHT
|
||||||
08-Jan-03 Sell -- RHT -- RED .. As:In:RB:Account-RSP -4.00 RHT -689.87 CAD
|
08-Jan-03 Sell -- RHT -- RED .. As:In:RBC-:Account-RSP -4.00 RHT -689.87 CAD
|
||||||
Ex:Fi:Commissions 9.95 USD -689.87 CAD
|
Ex:Financi:Commissions 9.95 USD -689.87 CAD
|
||||||
9.95 USD
|
9.95 USD
|
||||||
As:In:RB:Account-RSP 72.06 CAD -617.81 CAD
|
As:In:RBC-:Account-RSP 72.06 CAD -617.81 CAD
|
||||||
9.95 USD
|
9.95 USD
|
||||||
Ex:Financial:Fees 2.89 CAD -614.92 CAD
|
Expense:Financial:Fees 2.89 CAD -614.92 CAD
|
||||||
9.95 USD
|
9.95 USD
|
||||||
>>>2
|
>>>2
|
||||||
=== 0
|
=== 0
|
||||||
|
|
|
||||||
|
|
@ -10,6 +10,8 @@ reg --forecast-while="d<[2010/03/01]" --now=2009/11/01
|
||||||
>>>1
|
>>>1
|
||||||
09-Nov-01 Sample Expenses:Food:Dining $20.00 $20.00
|
09-Nov-01 Sample Expenses:Food:Dining $20.00 $20.00
|
||||||
Assets $-20.00 0
|
Assets $-20.00 0
|
||||||
|
09-Dec-01 Forecast transaction Expenses:Food $500.00 $500.00
|
||||||
|
09-Dec-01 Forecast transaction Assets $-500.00 0
|
||||||
10-Jan-01 Forecast transaction Expenses:Food $500.00 $500.00
|
10-Jan-01 Forecast transaction Expenses:Food $500.00 $500.00
|
||||||
10-Jan-01 Forecast transaction Assets $-500.00 0
|
10-Jan-01 Forecast transaction Assets $-500.00 0
|
||||||
10-Feb-01 Forecast transaction Expenses:Food $500.00 $500.00
|
10-Feb-01 Forecast transaction Expenses:Food $500.00 $500.00
|
||||||
|
|
|
||||||
|
|
@ -59,6 +59,7 @@ libledger_data_la_SOURCES = \
|
||||||
src/iterators.cc \
|
src/iterators.cc \
|
||||||
src/timelog.cc \
|
src/timelog.cc \
|
||||||
src/textual.cc \
|
src/textual.cc \
|
||||||
|
src/temps.cc \
|
||||||
src/journal.cc \
|
src/journal.cc \
|
||||||
src/archive.cc \
|
src/archive.cc \
|
||||||
src/account.cc \
|
src/account.cc \
|
||||||
|
|
@ -82,7 +83,6 @@ libledger_report_la_SOURCES = \
|
||||||
src/precmd.cc \
|
src/precmd.cc \
|
||||||
src/chain.cc \
|
src/chain.cc \
|
||||||
src/filters.cc \
|
src/filters.cc \
|
||||||
src/temps.cc \
|
|
||||||
src/report.cc \
|
src/report.cc \
|
||||||
src/session.cc
|
src/session.cc
|
||||||
|
|
||||||
|
|
@ -124,6 +124,7 @@ pkginclude_HEADERS = \
|
||||||
src/xact.h \
|
src/xact.h \
|
||||||
src/account.h \
|
src/account.h \
|
||||||
src/journal.h \
|
src/journal.h \
|
||||||
|
src/temps.h \
|
||||||
src/archive.h \
|
src/archive.h \
|
||||||
src/timelog.h \
|
src/timelog.h \
|
||||||
src/iterators.h \
|
src/iterators.h \
|
||||||
|
|
@ -133,7 +134,6 @@ pkginclude_HEADERS = \
|
||||||
src/session.h \
|
src/session.h \
|
||||||
src/report.h \
|
src/report.h \
|
||||||
src/filters.h \
|
src/filters.h \
|
||||||
src/temps.h \
|
|
||||||
src/chain.h \
|
src/chain.h \
|
||||||
src/precmd.h \
|
src/precmd.h \
|
||||||
src/csv.h \
|
src/csv.h \
|
||||||
|
|
|
||||||
18
tools/speed-test.sh
Executable file
18
tools/speed-test.sh
Executable file
|
|
@ -0,0 +1,18 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
cd ~/src/ledger
|
||||||
|
/bin/rm -fr ~/Products/ledger/opt
|
||||||
|
./acprep --no-python -j16 opt make check
|
||||||
|
|
||||||
|
COMMIT=$(git describe --long --all)
|
||||||
|
|
||||||
|
SPEEDS=$(./acprep --no-python -j16 opt make speedtest 2>&1 \
|
||||||
|
| grep "Finished executing command" \
|
||||||
|
| awk '{print $1}' \
|
||||||
|
| xargs)
|
||||||
|
|
||||||
|
echo $COMMIT,$(echo $SPEEDS | sed 's/ /,/g') >> speed.log
|
||||||
|
|
||||||
|
exit 0
|
||||||
Loading…
Add table
Reference in a new issue