public
Last active

  • Download Gist
ledger-copy-entry-to-bottom.el
Emacs Lisp
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
; i'm an elisp newbie
 
(defun vk-copy-ledger-entry-to-bottom ()
"Copy the current transaction to the bottom of the ledger"
(interactive)
(re-search-backward "^[12][90]")
(let ((beg (point)))
(forward-char)
(re-search-forward "^[12][90]")
(beginning-of-line)
(copy-region-as-kill beg (point))
(goto-char (point-max))
(yank '(non nil list))
(forward-word)
(forward-char)))

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.