John Wiegley
4681e58d7f
Converted the Ledger build system to use CMake
2012-05-20 04:48:05 -05:00
John Wiegley
a38ed141c1
Switched to Boost.PropertyTree for XML generation
2012-05-18 01:31:01 -06:00
John Wiegley
322d55823e
post.x = y defines metadata tag x
2012-04-04 02:28:07 -05:00
John Wiegley
5a615ec680
Make metadata tags case insensitive
2012-04-04 02:27:49 -05:00
John Wiegley
fcabd64a89
Whitespace fix
2012-04-04 02:26:34 -05:00
John Wiegley
22505d9527
Always call TRACE_CTOR at the end of constructors
2012-03-20 02:10:40 -05:00
John Wiegley
59cbcf703c
post_t's copy constructor wasn't copying xdata_
2012-03-13 00:03:56 -05:00
John Wiegley
e2afc783db
Increased file copyrights to 2012
2012-02-29 22:32:23 -06:00
John Wiegley
520ece2164
Fixed problem with the Python build
2012-02-29 14:43:16 -06:00
John Wiegley
656e46e182
Renamed actual/effective dates to primary/auxiliary
2012-02-28 03:02:16 -06:00
John Wiegley
4cf95497f9
Keep notes on their own line if parsed that way
2012-02-26 02:18:22 -06:00
John Wiegley
205dd3a1ee
Added has_date() method to item_t
2010-06-22 20:51:18 -04:00
John Wiegley
b80be82b8d
has_tag and get_tag now take an 'inherit' parameter
2010-06-18 02:19:39 -04:00
John Wiegley
dcffd218a1
Revised how Ledger handles the "current year"
...
Now when the Y directive sets the current year for a region, it affects
everything, as if the clock really were set back to that year.
2010-06-14 03:23:09 -04:00
John Wiegley
b1b4e2aadf
Add support for typed metadata
...
The metadata construct 'Key: Value' is now just a special case for
'Key:: "Value"'. Another after a :: in metadata setting is parsed as a
full value expression and typed as such. For example:
; Key:: $400 + $500
ledger -l 'tag("Key") < $1000'
2010-06-12 15:43:00 -04:00
John Wiegley
28c65cda51
Store metadata values as value_t instead of string
2010-06-12 14:55:18 -04:00
John Wiegley
dea2aed0b5
Untabified all source files
2010-06-11 17:02:25 -04:00
John Wiegley
a2bcfe4338
Increase item_t's flags to 16-bit
2010-06-10 12:04:00 -04:00
John Wiegley
d7b8095c3d
Tags were not being set properly on postings
2010-03-17 02:18:46 -04:00
John Wiegley
75b7294a6d
Rewrite the "print" command as a custom function
...
There ended up being too many corner cases for the generalized formatter
to handle.
2010-03-08 01:11:48 -05:00
John Wiegley
ab416f759f
Updated copyrights to 2003-2010
2010-03-05 22:14:10 -05:00
John Wiegley
9d61d3d621
Added actual_date() methods for items
2010-02-05 00:00:29 -05:00
John Wiegley
b78e22d52b
Added a "seq" sequence property for all items
...
This indicates the absolute parsing order of every transaction and
posting. It is 0 for generated items.
2010-02-04 18:23:52 -05:00
John Wiegley
e35394a70d
--data shouldn't modify the underlying item
2009-11-12 18:23:22 -05:00
John Wiegley
67c9cf134d
Added --date, similar to --account and --payee
...
This lets you do things like store a date as the value of a tag, then
run:
ledger --date='has_tag("Foo") ? to_date(tag("Foo")) : date' reg
2009-11-11 21:32:32 -05:00
John Wiegley
394c7bd8df
Removed a bunch of empty comments
2009-11-08 14:59:11 -05:00
John Wiegley
78e6770c4c
Segregated symbols into 5 separate namespaces
...
The different namespaces are:
Function Value expression functions, which receive a "context"
Option Command-line options
Precommand Commands which are invoked before reading the journal
Command Commands which are invoked after reading the journal
Directive Directives that occur at column 0 in a data file
This greatly eases the ability for Python uses to add intercept hooks to
change how the basic Ledger module functions. An example of what should
be possible soon:
import ledger
def my_foo_handler(value):
print "--foo received:", value
ledger.add_handler(ledger.Option, "foo=", my_foo_handler)
2009-11-04 20:40:48 -05:00
John Wiegley
b14c814fec
Whitespace fix
2009-11-04 20:40:42 -05:00
John Wiegley
6a78c24463
Stream out item metadata last in item_t::serialize
2009-11-01 21:15:46 -05:00
John Wiegley
2ae2c47a38
When copying an item, copy its metadata
2009-11-01 21:15:31 -05:00
John Wiegley
3909d2678e
Removed most #if 0 blocks and callout comments
2009-10-31 04:50:07 -04:00
John Wiegley
a757b19f51
Added serialization methods for most type
...
This allows journal_t objects to be completed serialized to disk and
deserialized.
2009-10-30 18:06:37 -04:00
John Wiegley
cb6f7cd54e
Add a position_t object for tracking item positions
...
It is also optional, which is useful for generated items.
2009-10-30 17:54:54 -04:00
John Wiegley
924c0a3013
Fixed a comment, and some whitespace
2009-10-30 17:48:31 -04:00
John Wiegley
8b2bf571d8
Added a comment about a confusing bit of code
2009-10-27 05:22:12 -04:00
John Wiegley
f161aea8ce
Removed reliance on strptime/strftime
...
The code now uses Boost's input and output facets for times and dates.
This ensures completely consistency regarding timezones and times, and
fixes the regression test that was broken while I was away coding in
London (where it was GMT-0 and I didn't notice the difference between
local and GMT).
2009-10-11 05:19:01 -04:00
John Wiegley
c11d325712
Reduced the #include dependency tree to a minimum
2009-03-04 23:53:43 -04:00
John Wiegley
944c63e6f2
The Great Renaming, Part II
...
The last commit did not contain the majority of changes because of a
slight mishap. This contains the real changeset.
2009-02-23 19:07:30 -04:00
John Wiegley
a577e8c48e
Added a new --raw option, for use with print
2009-02-21 19:45:13 -04:00
John Wiegley
ee5e0600aa
xact metadata searches get passed up to the entry
...
That is, if a metadata tag cannot be found in a transaction, look in the
parent entry to see if it was set there. Transactions "inherit"
notational details from their entries.
2009-02-14 05:37:53 -04:00
John Wiegley
6ca01af594
Fixed the use of --effective and --date-format (-y).
2009-02-09 17:27:54 -04:00
John Wiegley
02bd9d29cf
Improved an error message that was trying to show transaction context.
2009-02-08 20:05:56 -04:00
John Wiegley
408b819c6e
Greatly simplified the way option and command handlers are defined.
2009-02-05 21:20:09 -04:00
John Wiegley
3f960be96c
Removed all references to the old binary cache.
2009-02-04 20:57:14 -04:00
John Wiegley
2d941730b1
Largely removed all of Ledger's use of global variables, for the REPL's sake.
2009-02-04 19:55:27 -04:00
John Wiegley
1cc33531ea
Simplified the textual parser, and improved metadata support.
2009-02-04 03:34:37 -04:00
John Wiegley
2ce7ae376c
Removed used of src_idx.
2009-02-03 19:06:53 -04:00
John Wiegley
dfe04b9943
Removed some dead code.
2009-02-03 17:46:04 -04:00
John Wiegley
43c4636d9d
Removed the global references to session->report.
2009-02-03 13:03:10 -04:00
John Wiegley
9540406af1
Simplified error context handling.
2009-02-02 00:24:26 -04:00