Merge branch 'master' into ledger-mode-automatic-transactions
This commit is contained in:
commit
bee6605e08
7 changed files with 32 additions and 55 deletions
14
README-1ST
14
README-1ST
|
|
@ -11,22 +11,10 @@ almost certainly going to run into problems. In future, you can run
|
|||
'acprep update' again and again, and it will keep you updated to the
|
||||
very latest version.
|
||||
|
||||
I further recommend building both debug and optimized versions of Ledger, in a
|
||||
subdirectory of your source tree named 'build' (which acprep will manage for
|
||||
you, you simply need to create it):
|
||||
Now install it:
|
||||
|
||||
$ mkdir build
|
||||
$ ./acprep opt make
|
||||
$ ./acprep debug make
|
||||
|
||||
Now install the optimized version:
|
||||
|
||||
$ cd build/ledger/opt
|
||||
$ sudo make install
|
||||
|
||||
but know that you have 'build/ledger/debug' available for testing and
|
||||
for more useful bug reports.
|
||||
|
||||
===============================================================================
|
||||
COMMON CONFIGURE/BUILD PROBLEMS
|
||||
===============================================================================
|
||||
|
|
|
|||
|
|
@ -1422,7 +1422,7 @@ increase compatibility with other text manipulation programs and
|
|||
methods four additional comment characters are valid if used at the
|
||||
beginning of a line: @samp{#}, @samp{|}, and @samp{*} and @samp{%}.
|
||||
|
||||
Block comments can be made by use @code{@!comment} ... @code{@!end
|
||||
Block comments can be made by use @code{comment} ... @code{end
|
||||
comment}.
|
||||
|
||||
@smallexample
|
||||
|
|
@ -1432,10 +1432,10 @@ comment}.
|
|||
| and this,
|
||||
* and this.
|
||||
|
||||
!comment
|
||||
comment
|
||||
This is a block comment with
|
||||
multiple lines
|
||||
!end comment
|
||||
end comment
|
||||
@end smallexample
|
||||
|
||||
There are several forms of comments within a transaction, for example:
|
||||
|
|
@ -2000,7 +2000,7 @@ the account directive. For example:
|
|||
@smallexample
|
||||
apply account Personal
|
||||
2011/11/15 Supermarket
|
||||
Expenses:Groceries
|
||||
Expenses:Groceries $ 50.00
|
||||
Assets:Checking
|
||||
@end smallexample
|
||||
|
||||
|
|
|
|||
|
|
@ -1,23 +1,21 @@
|
|||
set(EMACS_LISP_SOURCES
|
||||
ldg-commodities.el
|
||||
ldg-complete.el
|
||||
ldg-exec.el
|
||||
ldg-fonts.el
|
||||
ldg-init.el
|
||||
ldg-mode.el
|
||||
ldg-new.el
|
||||
ldg-occur.el
|
||||
ldg-post.el
|
||||
ldg-reconcile.el
|
||||
ldg-regex.el
|
||||
ldg-report.el
|
||||
ldg-sort.el
|
||||
ldg-state.el
|
||||
ldg-test.el
|
||||
ldg-texi.el
|
||||
ldg-xact.el
|
||||
ldg-context.el
|
||||
ldg-schedule.el)
|
||||
ledger-commodities.el
|
||||
ledger-complete.el
|
||||
ledger-exec.el
|
||||
ledger-fonts.el
|
||||
ledger-init.el
|
||||
ledger-mode.el
|
||||
ledger-occur.el
|
||||
ledger-post.el
|
||||
ledger-reconcile.el
|
||||
ledger-regex.el
|
||||
ledger-report.el
|
||||
ledger-schedule.el
|
||||
ledger-sort.el
|
||||
ledger-state.el
|
||||
ledger-test.el
|
||||
ledger-texi.el
|
||||
ledger-xact.el)
|
||||
|
||||
# find emacs and complain if not found
|
||||
find_program(EMACS_EXECUTABLE emacs)
|
||||
|
|
@ -30,7 +28,7 @@ macro(add_emacs_lisp_target el)
|
|||
OUTPUT ${el}c
|
||||
COMMAND ${EMACS_EXECUTABLE}
|
||||
-L ${CMAKE_CURRENT_BINARY_DIR}
|
||||
-l ${CMAKE_CURRENT_BINARY_DIR}/ldg-regex.el
|
||||
-l ${CMAKE_CURRENT_BINARY_DIR}/ledger-regex.el
|
||||
-batch -f batch-byte-compile
|
||||
${CMAKE_CURRENT_BINARY_DIR}/${el}
|
||||
DEPENDS ${CMAKE_CURRENT_BINARY_DIR}/${el}
|
||||
|
|
|
|||
|
|
@ -150,7 +150,9 @@ MOMENT is an encoded date"
|
|||
(backward-paragraph 2)
|
||||
(re-search-forward ledger-iso-date-regexp)
|
||||
(replace-match date)
|
||||
(ledger-next-amount)))
|
||||
(ledger-next-amount)
|
||||
(if (re-search-forward "[-0-9]")
|
||||
(goto-char (match-beginning 0)))))
|
||||
|
||||
(defun ledger-delete-current-transaction (pos)
|
||||
"Delete the transaction surrounging point."
|
||||
|
|
|
|||
|
|
@ -196,8 +196,8 @@ namespace {
|
|||
|
||||
for (const char * p = buf; *p; p++) {
|
||||
if (*p == '.') {
|
||||
if (commodity_t::time_colon_by_default ||
|
||||
(comm && comm->has_flags(COMMODITY_STYLE_TIME_COLON)))
|
||||
if (("h" == comm->symbol() || "m" == comm->symbol()) && (commodity_t::time_colon_by_default ||
|
||||
(comm && comm->has_flags(COMMODITY_STYLE_TIME_COLON))))
|
||||
out << ':';
|
||||
else if (commodity_t::decimal_comma_by_default ||
|
||||
(comm && comm->has_flags(COMMODITY_STYLE_DECIMAL_COMMA)))
|
||||
|
|
@ -213,8 +213,8 @@ namespace {
|
|||
out << *p;
|
||||
|
||||
if (integer_digits > 3 && --integer_digits % 3 == 0) {
|
||||
if (commodity_t::time_colon_by_default ||
|
||||
(comm && comm->has_flags(COMMODITY_STYLE_TIME_COLON)))
|
||||
if (("h" == comm->symbol() || "m" == comm->symbol()) && (commodity_t::time_colon_by_default ||
|
||||
(comm && comm->has_flags(COMMODITY_STYLE_TIME_COLON))))
|
||||
out << ':';
|
||||
else if (commodity_t::decimal_comma_by_default ||
|
||||
(comm && comm->has_flags(COMMODITY_STYLE_DECIMAL_COMMA)))
|
||||
|
|
@ -744,7 +744,7 @@ void amount_t::in_place_unreduce()
|
|||
}
|
||||
|
||||
if (shifted) {
|
||||
if ("h" == comm->symbol() && commodity_t::time_colon_by_default) {
|
||||
if (("h" == comm->symbol() || "m" == comm->symbol()) && commodity_t::time_colon_by_default) {
|
||||
amount_t floored = tmp.floored();
|
||||
amount_t precision = tmp - floored;
|
||||
if (precision < 0.0) {
|
||||
|
|
|
|||
|
|
@ -151,7 +151,7 @@ account_t * journal_t::register_account(const string& name, post_t * post,
|
|||
// the payee indicates an account that should be used.
|
||||
if (result->name == _("Unknown")) {
|
||||
foreach (account_mapping_t& value, payees_for_unknown_accounts) {
|
||||
if (value.first.match(post->xact->payee)) {
|
||||
if (post && value.first.match(post->xact->payee)) {
|
||||
result = value.second;
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -69,15 +69,4 @@ end tag
|
|||
Income:Sales
|
||||
end tag
|
||||
|
||||
apply account Expenses
|
||||
bucket Assets:Checking
|
||||
2011/04/25 Tom's Used Cars
|
||||
Auto $ 5,500.00
|
||||
; :nobudget:
|
||||
|
||||
end account
|
||||
apply payee Amazon.com B.*k Store
|
||||
|
||||
2011/04/27 Book Store
|
||||
Books $20.00
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue