[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#17570: * lisp/vc/vc-hg.el (vc-hg-working-revision): Fix returning wo
From: |
Stefan Monnier |
Subject: |
bug#17570: * lisp/vc/vc-hg.el (vc-hg-working-revision): Fix returning working revision instead of last revision. |
Date: |
Fri, 06 Jun 2014 12:29:47 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) |
> I wish to fix the lisp/vc/vc-hg.el (vc-hg-working-revision) function with
> the `hg parent' command.
Good idea, thanks. But your patch's indentation was completely messed
up (as well as placement of line breaks).
I installed a cleaned up version into `emacs-24' (contrary to the
previous patch which I installed into `trunk' since it was a new
feature rather than a bug-fix).
Stefan
=== modified file 'lisp/ChangeLog'
--- lisp/ChangeLog 2014-06-06 14:25:39 +0000
+++ lisp/ChangeLog 2014-06-06 16:27:21 +0000
@@ -1,3 +1,8 @@
+2014-06-06 Santiago PayĆ i Miralta <santiagopim@gmail.com>
+
+ * vc/vc-hg.el (vc-hg-working-revision): Use "hg parent" and
+ vc-hg-command (bug#17570).
+
2014-06-06 Stefan Monnier <monnier@iro.umontreal.ca>
* international/mule-cmds.el (ucs-names): Add special entry for BEL
=== modified file 'lisp/vc/vc-hg.el'
--- lisp/vc/vc-hg.el 2014-05-11 02:01:08 +0000
+++ lisp/vc/vc-hg.el 2014-06-06 16:26:37 +0000
@@ -227,14 +227,11 @@
(defun vc-hg-working-revision (file)
"Hg-specific version of `vc-working-revision'."
- (let ((default-directory (if (file-directory-p file)
- (file-name-as-directory file)
- (file-name-directory file))))
- (ignore-errors
+ (or (ignore-errors
(with-output-to-string
- (process-file vc-hg-program nil standard-output nil
- "log" "-l" "1" "--template" "{rev}"
- (file-relative-name file))))))
+ (vc-hg-command standard-output 0 file
+ "parent" "--template" "{rev}")))
+ "0"))
;;; History functions
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- bug#17570: * lisp/vc/vc-hg.el (vc-hg-working-revision): Fix returning working revision instead of last revision.,
Stefan Monnier <=