Skip to content

Commit 94df75a

Browse files
committed
Issue 48: Document using { and } to move by transaction.
1 parent 1c3551b commit 94df75a

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

doc/ledger.txt

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,18 @@ Tips and useful commands
4949

5050
to catch most potential problems in your source file.
5151

52+
* Remap vim paragraph motion to move by transaction.
53+
54+
In vim, the "{" and "}" keystrokes move the cursor up and down by whole
55+
paragraphs. They can be redefined in ledger files to move by transaction
56+
instead. Add these lines to .vimrc:
57+
58+
au FileType ledger noremap { ?^\d<CR>
59+
au FileType ledger noremap } /^\d<CR>
60+
61+
The default definitions already work in ledger files that separate
62+
transactions with blank lines.
63+
5264
* `:call ledger#transaction_date_set('.'), "auxiliary")`
5365

5466
will set today's date as the auxiliary date of the current transaction. You

0 commit comments

Comments
 (0)