[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/beancount bde2d6c499 089/103: Add function to jump to prev
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/beancount bde2d6c499 089/103: Add function to jump to previous transaction |
Date: |
Mon, 29 Apr 2024 15:59:48 -0400 (EDT) |
branch: elpa/beancount
commit bde2d6c499ce630e4cc4beb79c0dffef2217e7b8
Author: Debanjum Singh Solanky <debanjum@gmail.com>
Commit: Daniele Nicolodi <daniele@grinta.net>
Add function to jump to previous transaction
This function mirrors the existing `beancount-goto-next-transaction'
---
beancount.el | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/beancount.el b/beancount.el
index c3f5614ec4..810dbc8f49 100644
--- a/beancount.el
+++ b/beancount.el
@@ -425,6 +425,20 @@ With an argument move to the next non cleared transaction."
(setq done t)))
(if (not done) (goto-char (point-max)))))
+(defun beancount-goto-previous-transaction (&optional arg)
+ "Move to the previous transaction.
+With an argument move to the previous non cleared transaction."
+ (interactive "P")
+ (beancount-goto-transaction-begin)
+ (let ((done nil))
+ (while (and (not done)
+ (re-search-backward beancount-transaction-regexp nil t))
+ (if (and arg (string-equal (match-string 2) "*"))
+ (goto-char (match-beginning 0))
+ (goto-char (match-beginning 0))
+ (setq done t)))
+ (if (not done) (goto-char (point-min)))))
+
(defun beancount-find-transaction-extents (p)
(save-excursion
(goto-char p)
- [nongnu] elpa/beancount e32e44e8d2 092/103: Added personal binding to aggregate balance binding., (continued)
- [nongnu] elpa/beancount e32e44e8d2 092/103: Added personal binding to aggregate balance binding., ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 73b2afcff6 087/103: (Merge remote-tracking branch 'github/main'), ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 42edc5bf07 083/103: Align amounts in balance directives in the same way as in postings, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 41039a8d7b 085/103: Added support for accounts in thing-at-point., ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 3725c02702 103/103: Update account name regex to allow starting with a number, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 77027e2cf8 037/103: beancount.el: Add outline-minor-mode integration tests, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 83cd9330e3 050/103: beancount.el: Include underscore and dash to metadata regexp., ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 8091f35803 056/103: beancount.el: Add beancount-electric-currency, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 449212459e 072/103: fix parenthses mismatch on beancount outline 1-8, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount d560451fda 071/103: Use beancount-level-N faces instead of org-level-N, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount bde2d6c499 089/103: Add function to jump to previous transaction,
ELPA Syncer <=
- [nongnu] elpa/beancount c77e340ed2 003/103: ., ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount e8a5bce28c 086/103: Fix typo in beancount-number-alignment-column docstring, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 72956f0f0e 097/103: Change sign of prefix argument for `beancount-insert-date`, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 7a0ef01d1f 066/103: Add command to open file with fava, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount aab2a23f15 074/103: Fix headlines fontification test, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 519bfd868f 093/103: (Merge remote-tracking branch 'github/main'), ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 687775da63 088/103: Minor refactoring of region commands (with no expected functionality changes)., ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 94bae42833 091/103: Extend CI to run tests on Emacs 28 too, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 0f1e33067e 100/103: Fix a bug where `beancount-accounts` was read from the minibuffer, ELPA Syncer, 2024/04/29
- [nongnu] elpa/beancount 763a8d3fe4 095/103: Add docstrings, ELPA Syncer, 2024/04/29