From dd22fbdbb002a43442f55300c798f325e952e479 Mon Sep 17 00:00:00 2001 From: SiameseCat Date: Wed, 24 Feb 2016 19:27:17 -0500 Subject: [PATCH] Fixing bug getting commit message for revision being amended. Allowing commit to be reworded without changing files. --- monky.el | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/monky.el b/monky.el index d7226a8..0b157e1 100644 --- a/monky.el +++ b/monky.el @@ -2894,14 +2894,12 @@ With a non numeric prefix ARG, show all entries" "Amends previous commit. Brings up a buffer to allow editing of commit message." (interactive) - (if (not (or monky-staged-files (monky-merge-p))) - (error "Nothing staged") - ;; get last commit message - (with-current-buffer (get-buffer-create monky-log-edit-buffer-name) - (monky-hg-insert - (list "log" - "--template" "{desc}" "-r" "-1"))) - (monky-pop-to-log-edit 'amend))) + ;; get last commit message + (with-current-buffer (get-buffer-create monky-log-edit-buffer-name) + (monky-hg-insert + (list "log" + "--template" "{desc}" "-r" "."))) + (monky-pop-to-log-edit 'amend)) (provide 'monky)