| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Fixes #2129
|
|
|
|
|
| |
fix https://github.com/ledger/ledger/issues/2338
fix https://github.com/ledger/ledger/issues/2340
|
| |
|
|
|
|
|
| |
Also, support matching provided hashes against a prefixed of the generated
hash.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The following details of a posting contribute to its hash:
fullname of account
string representation of amount
Each posting hashes contributes to the transaction hash, which is compromised
of:
previous transaction’s hash (as encountered in parsing order)
actual date
optional auxiliary date
optional code
payee
hashes of all postings
Note that this means that changes in the “code” or any of the comments
|
|
|
|
| |
and reply #ifdev HAVE_ with #if HAVE_
|
| |
|
| |
|
|
|
|
| |
[skip ci]
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ensure the path of file to include in `instance_t::include_directive`
is always an absolute path.
Previously when the journal file is given through stdin, we prepend a
"./" to the filename to include. However, in Boost >= 1.77,
`path::normalize` strips the leading "./" [1]. Our `resolve_path`
function calls `normalize` and thus now it returns "file" for "./file"
instead of the previous "./file".
This change causes a failing test regress/BF3C1F82-2 [2], and also
breaks the `include` directive for stdin input:
$ touch file-to-include
$ echo "include file-to-include" | ledger -f - reg
gives
While parsing file "", line 1:
Error: File to include was not found: "file-to-include"
Therefore, we change to prepend the `context.current_directory` to
make the filename absolute in this case as well. The test
regress/BF3C1F82-2 is also updated to match the new output.
Fixes #2075.
[1] https://github.com/boostorg/filesystem/commit/16bd89b7c0398d0dc5904148a865ef3fc3ece7ec
[2] https://github.com/ledger/ledger/issues/2075
|
|
|
|
| |
closes 1948
|
|
|
|
|
|
|
|
| |
Handle files that don't end with a new line. Throw an error when the buffer
size is exceeded.
Fixes #516
Contributes to #1149
|
|
|
|
|
| |
Payees declared on posting's metadata are now validated with `--check-payees`
option. Also, their aliases are now considered on reports as well.
|
|
|
|
|
|
|
|
|
|
|
| |
Ledger is treating balance assignments that have a 0 diff as having
a null posting, leading to the posting being auto-balanced and
therefore causing incorrect values to be returned for the transaction.
I fixed this by just making the posting equal to amt - amt (0 in the
right commodity).
Fixes #1942
|
| |
|
|
|
|
|
|
|
|
| |
Before this commit, doing something like 'include data/*.dat' would
produce undesired behaviour because the matches for 'data/*.dat' would
not be sorted correctly.
See https://github.com/ledger/ledger/issues/1659 for details.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
The directive `apply account` and similar directives (fixed, year...)
require an argument. Ensure that an argument is given.
Fixes #553
Fixes #1854
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Without these changes, whether an account's balance is virtual
or real is not considered when asserting it's balance. This lead
to situations where the user must consider their virtual postings
when attemping to assert the real balance of the account. See
test/regress/543_a.test for that testcase, taken from the original
issue. This commit also includes other, fringe, situations that I
noticed while working on the fix. It essentially just adds a separate
attribute to the account class(?) that hold's the account's "real"
balance, which is only updated when the user attempts an assertion on a
real account. The virtual account's balance is updated the way it always
was.
|
|
|
|
| |
Fixes #1816
|
|
|
|
| |
Fixes #1753
|
|\
| |
| |
| |
| | |
Drop conditionals for Boost earlier than 1.49
|
| |
| |
| |
| |
| |
| |
| | |
Ledger requires Boost 1.49 or later and enforces this in
CMakeLists.txt. This means BOOST_VERSION will always be
104900 or higher. Also, since Boost 1.46,
BOOST_FILESYSTEM_VERSION is 3.
|
|/ |
|
|\ |
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
[ci skip]
|
| | |
|
|\ \
| | |
| | | |
Fix Bug 1182: Error message for parse failure after '='
|
| | | |
|
|/ /
| |
| |
| | |
[ci skip]
|
| | |
|
| |
| |
| |
| | |
This fixes error-in-include.test, dir-apply.test, 6188B0EC.test, and 89233B6D.test when running under msys2 on Windows. The manual computation is incorrect when there are both forward slash and backward slash characters in the path.
|
|/ |
|
|
|
|
| |
[ci skip]
|
|
|
|
|
| |
when year was specified with literal Y or year directive, but not
when using apply year.
|
|
|
|
|
|
|
| |
A literal Y directive or ‘year’ directive with an empty or invalid
argument, e.g. ‘2o14’ (that is a small letter ‘oh’ instead of a zero)
would fail with the following rather unhelpful error message:
Error: bad lexical cast: source type value could not be interpreted as target
|
|
|
|
| |
Only Y2014 or apply year 2014 would actually set the year for the
following transactions; year 2014 would silently do nothing.
|
|
|
|
|
|
| |
The following script makes it a no-brainer:
% NEXT_YEAR=2015; ag -l 'Copyright.*Wiegley' \
| xargs sed -i '' -e "s/\(Copyright.*\)-20[0-9]\{2\}/\1-${NEXT_YEAR}/"
|
|
|
|
| |
[ci skip]
|
|
|
| |
This fixes parsing of transactions with single-character payees and comments.
|
|
|
|
| |
Patch from John Wiegley
|
|
|
|
| |
posting, it always has a priority over entire transaction status.
|
|
|
|
|
|
|
|
| |
When a cost was specified without a whitespace after the @ symbol,
as in @$5.01, this was incorrectly parsed as 5.01 (losing the
commodity) rather than $5.01.
Bug fix for #1050
|
|
|
|
| |
Correction is to not use uninitialized amount
|