Commit graph

422 commits

Author SHA1 Message Date
Craig Earls
d63d845f41 Fix bug 1030 improperly placing the stays mark if the Payee starts with a digit. 2014-05-11 08:48:42 -07:00
Craig Earls
20b915668f Merge commit 'dbfbf2bc893de3c44dcc08c33811bc274f647672' 2014-05-09 20:40:42 -07:00
Steve Purcell
9da91b8fae Refactor macros in ledger-context.el to byte compile cleanly 2014-05-09 21:11:01 +01:00
Craig Earls
2906a2f759 Merge commit '62bdb2f13a31449ca6f439ee121162647c39855e' 2014-04-24 06:53:04 -07:00
Christophe Rhodes
e2d3e02b0d fix ledger-iso-date-regex, abusing its name slightly
the year field in dates is sort-of optional, given "year" or "Y"
directives.  Make the date regex understand this.  (This has been lightly
tested with C-c C-a, but the rest of the uses of ledger-iso-date-regex
have only been eyeballed, not properly audited or tested)
2014-04-23 17:45:42 +01:00
Christophe Rhodes
ad4eac43a9 add "year" handling to ledger-iterate-regex 2014-04-23 17:45:41 +01:00
Christophe Rhodes
9c3535823a improve C-c C-a (ledger-xact-insert-transaction) behaviour
When the right place to add a transaction is after all existing
transactions, add it just after the last transaction rather than at the
end of the buffer.  (Otherwise the transactions get added after Local
Variables blocks and any other endmatter.)
2014-04-23 17:07:23 +01:00
Craig Earls
3112851e97 Merge commit 'b9078dc93ffdb526efd0a859a73cc3076108f6b2' 2014-03-25 18:56:32 -07:00
Jamie Nguyen
33ce4a76a1 Update old FSF address 2014-03-23 23:42:21 +00:00
Vincent Bernat
cdeed89dbd lisp: use more legible colors on dark backgrounds
On dark backgrounds, the color for the current transaction makes the
text quite unreadable. Let's use a darker color in this case. Maybe some
other colors could be adjusted.
2014-03-23 02:09:49 +01:00
Craig Earls
bb8e000d5b Make reconcile window refresh xact locations after a delete operation 2014-02-24 14:16:46 -07:00
Marcin Borkowski
b1cfeb0015 Add option ledger-complete-ignore-case
and change ledger-pcomplete accordingly
2014-02-03 22:52:08 +01:00
Alexis Hildebrandt
2b9208e850 Bump copyright information to 2014 2014-02-02 12:36:22 +01:00
Johann Klähn
61a466636b Merge pull request #229 from EvilBit/master
Fixed emacs lisp compilation
2014-01-25 05:20:52 -08:00
Craig Earls
0ed6b0f1c3 Fixed some formatting problems and fixed bug 1007 aligning decimal comma amounts with period thousand separators. 2014-01-13 14:55:48 -07:00
Craig Earls
aec2c7af3f Fix issue in ledger-fully-complete-xact to deal with possible trailing spaces after a payee 2014-01-13 13:14:02 -07:00
Steve Purcell
3b5f496536 ledger-mode: only modify completion-at-point-functions locally
Without this patch, the addition of pcomplete-completions-at-point
leaks into the global value of completion-at-point-functions.

See #227
2014-01-07 20:33:08 +00:00
Craig Earls
af84005a52 Backed out recent changes that broke the complete cycling behavior. 2014-01-07 13:25:07 -07:00
Oskar Kohout
5fdb7fe6e7 Move emacs lisp installation destination to subdirectory 2014-01-04 12:07:59 +01:00
Oskar Kohout
ba60418991 Fix emacs lisp build chain 2014-01-04 11:52:23 +01:00
Moritz Ulrich
741a275cc9 Use `ledger-read-date' where applicable. 2014-01-02 19:00:37 +01:00
Moritz Ulrich
8406adce0e ledger-read-date': Use ledger-minibuffer-history'. 2014-01-02 18:55:25 +01:00
Moritz Ulrich
09ef323a73 ledger-reconcile: Add option to insert an effective date when clearing transactions. 2014-01-02 18:44:15 +01:00
Moritz Ulrich
26bc890d88 ledger-insert-effective-date': use ledger-read-date'.
Running `ledger-insert-effective-date' will now prompt for a date with
a pre-filled value of the `(ledger-year-and-month)' ("2014/01/"). Just
pressing RET without inserting the 'day'-portion will insert the date
of today.
2014-01-02 18:43:53 +01:00
Moritz Ulrich
3ff5fddafd Add `ledger-read-date' - Read date & default to today. 2014-01-02 18:24:54 +01:00
4ourbit
e00ed8c770 Fix for pcomplete Metadata rule. 2014-01-01 22:00:26 +01:00
4ourbit
316b1b7cfe Plugging ledger pcomplete into completion-at-point.
Added documentation on how to use pcomplete transparently via completion-at-point.
2014-01-01 22:00:26 +01:00
4ourbit
383f17f114 Context-aware pcomplete rules.
Provide completions based on information retrieved with 'ledger-context-at-point'.
To support step-by-step completion of transactions some more patterns were added
to 'ledger-line-config'. The actual completion rules mostly reuse some of the
convenient input commands that are buried in ledger-mode. Using the standard
pcomplete termination string (" ") to allow a "context switch" at the end of each
completion step.
2013-12-31 03:16:57 +01:00
Moritz Ulrich
9f694169a8 ledger-mode: Introduce `ledger-default-date-format'.
Some elisp functions depend on a date-format supplied in ~/.ledgerrc. Change these by introducing a default ("%Y/%m/%d").

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-30 01:41:31 +01:00
Moritz Ulrich
7dd82f8bac Improve `ledger-insert-effective-date'.
The function now replaces already existing effective dates in the same
line.

With a prefix (C-u C-c C-t), remove the current effective date.

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-30 00:50:48 +01:00
Moritz Ulrich
6dbb36f525 ledger-mode: Add `ledger-remove-effective-date'.
Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-30 00:22:43 +01:00
Moritz Ulrich
15b94e8f44 emacs-mode: Prefix every function/variable/macro with ledger-.
This is the common convention in Emacs Lisp. Not following it might
cause problems with other packages as functions/variables/macros are
always visible to other modules.

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-29 22:56:45 +01:00
Moritz Ulrich
c0812b91bf Fix `ledger-string-to-number' for decimal-comma
--=-=-=
Content-Type: text/plain

Hi John,

Small bug, caused by ill-formatted elisp. This is a small patch, so i
think making a fork & opening a Pull Request is a bit too much. I'll go
this route if I make bigger contributions in the future.

From de1fb19ded5300a227d58e3d3094928b211db09b Mon Sep 17 00:00:00 2001
From: Moritz Ulrich <moritz@tarn-vedra.de>
Date: Sat, 28 Dec 2013 22:37:54 +0100
Subject: [PATCH] ledger-string-to-number: Fix nil return value with
 decimal-comma.

Unfavorable formatting hid this bug pretty well. In case of true-ish
`decimal-comma' or "decimal-comma' in `ledger-environment-alist', the
ill-formatted `if' (and the whole function) returns nil.

Signed-off-by: Moritz Ulrich <moritz@tarn-vedra.de>
2013-12-28 18:11:25 -06:00
4ourbit
f18833c78b fix for unexpected point movement
bug fixed: point moves to previous char when called at whitespace-only line
2013-12-23 14:06:20 +01:00
Rémi Vanicat
ead3bbb7bf ledger-schedule-upcoming take argument.
One can forget to run ledger-schedule-upcoming for some time. Then there
is the risk that ledger-schedule-look-backward is too short. This will
open the possibility to use a different file, or to change the period
backward or forward for this kind of case.
2013-12-12 18:56:16 +01:00
Rémi Vanicat
b4897a9e7c Pop the new schedule buffers 2013-12-12 18:56:05 +01:00
Steve Purcell
dcd9cc4b17 ledger-mode: Also bind g to ledger-report-redo, as is standard elsewhere 2013-12-11 19:08:56 +00:00
Steve Purcell
ccaaf7e235 ledger-mode: Fix a number of byte-compilation warnings 2013-12-11 08:36:22 +00:00
Steve Purcell
12816a77e3 ledger-mode: Add missing argument to ledger-delete-current-transaction 2013-12-11 08:36:22 +00:00
Steve Purcell
6eca277bbc ledger-mode: Remove duplication in ledger-set-{year,month} 2013-12-11 08:36:22 +00:00
Steve Purcell
75a2d9d31e ledger-mode: Add namespace prefix to highlight-overlay
make-variable-buffer-local is a top-level form: this commit moves that
call from ledger-mode to next to the variable's declaration.
2013-12-11 08:36:22 +00:00
Steve Purcell
aaf20ab07f ledger-mode: Use easymenu to remove boilerplate
Among other benefits, this lets us define the menu entries from top to
bottom, rather than in reverse.
2013-12-11 08:31:07 +00:00
Steve Purcell
c85643b04e ledger-mode: declare keymaps at the top level 2013-12-09 20:41:01 +00:00
Steve Purcell
a74053b010 ledger-mode: define and use a syntax table so that comments are handled properly
Specifically, functionality which uses syntax-ppss to detect comments
needs the syntax table to be aware of them. A prime example is
goto-address-prog-mode.

This commit adds a basic syntax table for this purpose.
2013-12-09 19:11:23 +00:00
Rémi Vanicat
5b4400b2d0 Reload init when calling ledger-init-load-init-file again.
When the ledger-init-load-init-file was called again, it used to parse ledger
init file, and to throw away the result. No you can use it to load this file
again when you have change something in it.
2013-11-26 13:19:38 +01:00
Craig Earls
fc716a5ca1 Merge branch 'ledger-mode-automatic-transactions'
Conflicts:
	lisp/ledger-post.el
2013-11-12 09:24:29 -07:00
Craig Earls
f34ad34b89 Fix values pushed to calc 2013-11-12 09:21:44 -07:00
Craig Earls
1db0b0892c Merge branch 'master' into ledger-mode-automatic-transactions 2013-11-06 08:48:54 -07:00
Steve Purcell
979b5b990a Fix provided feature to match file/package name
For `require` to work correctly, the provided feature name
must match the name of the file.
2013-11-03 21:34:55 +00:00
Craig Earls
bee6605e08 Merge branch 'master' into ledger-mode-automatic-transactions 2013-09-20 07:26:44 -07:00