emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/perl-doc 1882031ee6: * Bugfix: perl-doc.el (perl-doc-fi


From: ELPA Syncer
Subject: [elpa] externals/perl-doc 1882031ee6: * Bugfix: perl-doc.el (perl-doc-file): Make sure that "~" is expanded, and
Date: Thu, 6 Jul 2023 18:58:18 -0400 (EDT)

branch: externals/perl-doc
commit 1882031ee64485b4da8c067930fcf0890cbaf410
Author: Harald Jörg <haj@posteo.de>
Commit: Harald Jörg <haj@posteo.de>

    * Bugfix: perl-doc.el (perl-doc-file): Make sure that "~" is expanded, and
    switch to the directory where the file is located.
---
 perl-doc.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/perl-doc.el b/perl-doc.el
index 253160665a..9d80afb76c 100644
--- a/perl-doc.el
+++ b/perl-doc.el
@@ -411,8 +411,9 @@ Does better formatting than man pages, including 
hyperlinks."
 This is the same as running `perl-doc' with FILE as an argument,
 but provides file-name completion."
   (interactive "f")
-  (perl-doc file)
-  )
+  (let ((absolute-path (expand-file-name file)))
+    (setq-local default-directory (file-name-directory absolute-path))
+    (perl-doc absolute-path)))
 
   ;; Make elint-current-buffer happy
 (defvar text-scale-mode-amount)                ; in face-remap.el, which we 
require



reply via email to

[Prev in Thread] Current Thread [Next in Thread]