From f1a0e079dba65501b461743e6d5dee305b3bc2f6 Mon Sep 17 00:00:00 2001 From: Kazu Yamamoto Date: Thu, 11 Mar 2010 14:15:28 +0900 Subject: [PATCH] get the latest path. --- elisp/ghc-doc.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/elisp/ghc-doc.el b/elisp/ghc-doc.el index 756df61..189db8d 100644 --- a/elisp/ghc-doc.el +++ b/elisp/ghc-doc.el @@ -28,7 +28,9 @@ (defun ghc-resolve-document-path (pkg) (with-temp-buffer (call-process "ghc-pkg" nil t nil "field" pkg "haddock-html") - (goto-char (point-min)) + (goto-char (point-max)) + (forward-line -1) + (beginning-of-line) (when (looking-at "^haddock-html: \\([^ \n]+\\)$") (match-string-no-properties 1))))